Sign In  |  Register
 
 DotNetNuke Powered!
DotNetNuke Support Forums

DNN Scheduler, Request Method and HttpContext

Rate this topic:

Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

AuthorMessages
lneville
Posts:53



05/02/2008 5:50 AM  

I have written a method inside CATALook to create and email invoices out to customers with the intention of scheduling this to occur periodically via the DNN Scheduler. However, what I am finding is that my function fails because HttpContext is not available when it is called by the scheduler (the function uses HttpContext for various things and I can't figure out how to rewrite it without that dependancy).

Now, this problem has been raised numerous times in the past, but I thought that nowadays the problem could be bypassed by setting the Scheduler Mode to Request Method. Request Method supposedly means that the scheduler runs inside a request call and I thought this meant that HttpContext would be available. However my function still fails because inside the function HttpContext.Current Is Nothing.

Strangely, the function sometimes works, but I can't figure out what is different when it does work.

Can you explain why Request Method doesn't make HttpContext available and what if anything I can do to get hold of it? My last resort is to try "manufacturing" an HttpContext as suggested here:

http://www.dotnetnuke.com/Community/Blogs/tabid/825/EntryID/436/Default.aspx

lneville
Posts:53



05/02/2008 6:04 AM  

Also, what would cause the function to sometimes succeed (i.e. HttpContext to suddenly be available)?

Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

Forums >DotNetNuke Support >General-DNN-Help > DNN Scheduler, Request Method and HttpContext



ActiveForums 3.7
Visit our Store for great DotNetNuke Modules and Skins
DNNMasters Sitemap/Google Sitemap 3.0

Item codeSM3-01
Price$29.00
Product Information 
DotNetNuke CSS NavMenu 3.3 (Developers)

Item codeCSSNM33DEV
Base Price$149.00
Product Information 
Snapsis PageBlaster 3.3.1 for DotNetNuke - Professional Edition

AuthorJohn Mitchell
Base Price$79.00
Product Information 
XDAkuna (Web 2.0 CSS XHTML Skin)

Item codeXDAkuna
AuthorNina Meiers
Price$49.00
Product Information