locked
Using Session before AcquireRequestState RRS feed

  • Question

  • User-1746188426 posted

    I catch unhandled exception at Application_Error and save information about exception to Session to transfer it to error page. But unfortunately sometimes I get an exception Application_Start (before AcquireRequesState). That's why Session is null and therefore unavailable. Of course I can save information, for example, to Cache, there is probability that 2 users will get 2 differerent exception at the same time (so Cache is inappropriate). Is there any ability to use Session in such situations? Or may be threre are some other ways of solving this problem?

    Sunday, March 2, 2008 1:14 PM

All replies

  • User312496708 posted

    Create a collection at the applictaion level and save the required values in teh application level variables. Also you can pass the information to the error page using the querystring

    Sunday, March 2, 2008 10:41 PM
  • User960609757 posted

    hi,

    check this url regarding AcquireRequestState,

    http://www.eggheadcafe.com/articles/hijacksession.asp

    Monday, March 3, 2008 1:10 AM
  • User-1746188426 posted
    Create a collection at the applictaion level and save the required values in teh application level variables.

    I think there are no principal differences between using Application collection or Cache. That's why it is not appropriate.

    Also you can pass the information to the error page using the querystring
     

    This information shouldn't be visible for all users. So it's not appropriate too. 

    Monday, March 3, 2008 12:03 PM
  • User-1746188426 posted

    check this url regarding AcquireRequestState,
     

    Sorry, but I do not understand, how this link is connected to my problem.

    Monday, March 3, 2008 12:20 PM