Redirecting in the mobile framework

Discussion in 'ASP .Net Mobile' started by amn3sia, Jul 19, 2006.

  1. amn3sia

    amn3sia Guest

    I'm using custom authentication and when redirecting I was handling it like
    any other non-mobile web app I've done before. I was using
    Response.Redirect(). Now I've noticed that there is a
    MobilePage.RedirectToMobilePage() method. Should I be using this instead of
    Response.Redirect()?

    I was receiving the following error in my app:
    "The page requires session state that is no longer available. Either the
    session has expired, the client did not send a valid session cookie, or the
    session state history size is too small. Try increasing the history size or
    session expiry limit."

    Stack trace: at
    System.Web.UI.MobileControls.MobilePage.OnViewStateExpire(EventArgs e)
    at
    System.Web.UI.MobileControls.MobilePage.LoadPageStateFromPersistenceMedium()
    at System.Web.UI.Page.LoadAllState()
    at System.Web.UI.Page.ProcessRequestMain(Boolean
    includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)


    I'm checking the Session state in the OnInit event so they should be
    redirected before this point. Also I read in the documentation for
    Response.Redirect() that in cookieless forms using the ~/ for the application
    root can cause new Sessions to be created which I was also doing. Do you
    think either or both of these could be the cause of my problem?
    amn3sia, Jul 19, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. chen selina
    Replies:
    0
    Views:
    1,253
    chen selina
    Jul 13, 2010
  2. iewhhos iewhhos

    Redirecting to mobile page give an unwanted message.

    iewhhos iewhhos, Jul 15, 2004, in forum: ASP .Net Mobile
    Replies:
    1
    Views:
    144
    _thedebugger
    Jul 21, 2004
  3. Martin

    Problem Redirecting Mobile ASP pages

    Martin, Mar 22, 2005, in forum: ASP .Net Mobile
    Replies:
    2
    Views:
    119
    Martin
    Mar 28, 2005
  4. Sathish Kumar K

    Redirecting Mobile Page to a different page and come back

    Sathish Kumar K, Jun 28, 2005, in forum: ASP .Net Mobile
    Replies:
    1
    Views:
    256
  5. Pankaj Jain
    Replies:
    1
    Views:
    804
    Duncan McC
    Jun 11, 2008
Loading...

Share This Page