Browser back cause PostBack RRS feed

  • Question

  • User512894520 posted
    I am using .Net 2.0 for Mobile applications. My application basically reloads the same page with different query paramters based on the action selected. I don't want to use different forms  because I can't divide my application logically to use different forms. Anyways, the question is, whenever press the back button of either a Mobile phone or a PDA, it results in a MobilePage.Postback. Is this behaviour expected? I was under the impression that a browser back would only reload the html/wml of an already cached page. Is there a Web.Config setting that I am missing. Or do I have my concepts all wrong? Please help. Thanks in advance.
    Tuesday, November 21, 2006 2:03 AM

All replies

  • User512894520 posted
    Additionally, from my aspx MobilePage when I use Response.Redirect() or a RedirectToMobilePage() to make a fresh call to the same page, then a HTML browser (pda, desktop IE, blackberry) recognizes this as a fresh request (ie. Page.IsPostBack = false on the next hit of Page_Load for this aspx), but a mobile phone browser interprets this Redirect also as a Postback instead of a new request. Is there any way of categorically stating that a Redirect should be considered as a fresh call instead of a PostBack even if the target happens to be the same page as this?? Any help/suggestion would be greatly appreciated. Thanks.
    Tuesday, November 21, 2006 6:48 AM
  • User512894520 posted

    When I couldn't fix the problem of a mobile phone browser masquerading a Response.Redirect to the same page as a PostBack instead of a fresh call, I decided to call Redirect for an intermediate page. Now, when I call the Redirect for this new page I get another exception. :-((

    Invalid viewstate.
    Client IP:
    User-Agent: Nokia6230/2.0 (04.44) Profile/MIDP-2.0 Configuration/CLDC-1.1
    Path: /EzService/I.aspx

    where I.apsx is the page I am trying to Redirect to.

     I read a forum entry about some similar error with MacState invalid of something and as per that entry, changed my web.config to have the following entries to my <System.Web> <pages> element : <pages validateRequest="false" enableEventValidation="false" viewStateEncryptionMode="Never">

     But even this does not help. Someone please point me to some kind of a solution.

    Tuesday, November 21, 2006 9:11 AM