.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Web Form breaks after using the browser's back button

Posted By:      Posted Date: August 31, 2010    Points: 0   Category :ASP.Net
I have a web form that allows a user to put some data in a textbox and click a button to do a search on that data.  It opens up a Sql Server Reporting Services report using the data they entered on the previous page.  If they use the browser's back button to go back and enter some different criteria to search on, the buttons don't work anymore. Any ideas or suggestions on what would cause this?   Thanks! 

View Complete Post

More Related Resource Links

Infopath 2007 print view in browser enabled form with Print button


Hi i create a  print view brower enabled form in Infopath 2007 with header and footer. In Infopath works fine. Margin was ok, header and footter to. But then i try to print this browser the margin, header and footer it changes to default setting of browser ? I try also create a print button in form with VS 2008 code, but method :

this.print(); not working.

It is possible to print the "print view" in browser as the same like in Infopath 2007? Does anyone have the code how to create a print button in C# on browser enabled form?

Creating a "Save Button" in a browser based Form

I'm not sure if I'm missing something obvious, but I need to have the funtionality of the "Save Button", which is available and works on the tool bar, available in the form...and I can't seem figure out how to do it.I've found examples, in this forum, of how to use the "Submit Button" to act as the "Save Button", which did work for me, but only when specific basic criteria was met.The criteria that I now have is that I'm initiating a workflow to automatically start when a new item is created.  My workflow then moves the form to one of a few possible different form libraries, based on the logic in my workflow.  The different form libraries are to manage different teams of people that would have access to the Form and then that team would process the form accordingly.My specific situation: 1 - User opens a new form (works) 2 - User enters data and then submits the new form (works) 3 - Workflow is initiated and the form is moved to another form library to be worked on by a select group of people (works) 4 - The form is opened and reviewed and some changes are made to the form data by the select group of people (works) 5 - The form data in the form libary is updated (works, but only if the save button is pressed in the tool bar and then manually closes t

Back & forward button of browser hide...

Hiwithout script can i hide back & forward button of browser ..here lot of solution given but not working properly so please give me solutionthankscraj

Browser back button issue when ViewState stored in DB.

I implemented the solution of storing the ViewState in DB (since we were getting lots of Invalid & Corrupt Viewstate errors on our site daily) as given in the following website:http://weblogs.asp.net/adweigert/archive/2004/03/09/86628.aspxThe solution was implemented in one of the aspx pages on our site that behaves like a wizard (not using the wizard control though). After starting to store the viewstate in DB, the Invalid ViewState errors were eliminated completely, but I am now facing the following problem:1) User selects radiobutton1 of the two radiobutton choices on Page 2 of the wizard, a postback happens which displays some extra information on the page based on the selection. Now the user hits the next button on the page that also does a postback & displays Page 3.2) On Page 3, user hits the "back button" of the browser instead of the "previous page" button that is available on that page.3) This displays Page 2 from cache in original state(without any selections made). When user now selects radiobutton2, a postback is supposed to happen, but it does not. User then clicks "next" button on Page 2 (a postback does happen here however), & Page 3 is displayed, but it still thinks that radiobutton1 was selected (the original selection that was made in step1) on the previous page & hence displays information accordingly.I am assumi

Mobile redirect and the browser back button

Has anyone here ever successfully constructed a two-page mobile website with VB, one page for input and one page for displaying results?  If so, how do you call the results page and can you return to the input page using the back button on your mobile browser?  I have no problem creating such a website for regular browsers, but I simply cannot construct one for the iPhone or the Droid ... you can't return to the first page via the backbutton and still have it be functional; all you have is the graphics.  There is no load event for the page you're returning to.  It seems like mobile browsers don't handle server-side redirects properly.  If you open a new page via a hyperlink, you can return to the page you were on and it will still be functional; not so following a redirect to another page on your site. I've experimented endlessly with cache settings, redirect parameters, and the pagestatepersister class to no avail.  I need to know if I'm on a futile quest.  Can anyone offer confirmation for can do/can't do?    

Browser Back button

Hello,    Is there any way to know if the post back happen because of the broswer back button. Or I have a reapter control can i use response.redirect on a image to go to another page.Because i am using <a href now but problem is I want to know the previous page , for that i used URLRefferal but it is not getting the right page because it is a <a href not response.redirect.   Thank, 

how to disable back button of your browser

i want to know how can i restrict any user to access any webpage after logging out

ModalPopupExtender problem with browser back button


ModalPopUpExtender shows popup when user clicks browser back button.

I saw this thread but I could find the solution for this problem.


mesajrapor1 is my user control which contains the modalpopupextender

Here is my code:


protected void DataList1_ItemCommand(object source, DataListCommandEventArgs e)
        HyperLink hyp = (HyperLink)e.Item.FindControl("hypGonderenAD");
        Label lblicer = (Label)e.Item.FindControl("lblIcerikMesaj");
        Label midlbl = (Label)e.Item.FindControl("lblIdMesaj");
        Label sidlbl = (Label)e.Item.FindControl("Label3");

        if (e.CommandName == "SikayetEt")
            mesajrapor1.RaporGonder(hyp.Text.ToString(), lblicer.Text.ToString(), Convert.ToInt32(midlbl.Text), Convert.ToInt32(sidlbl.Text));

Navigating Web Project with Browser's Back/Forward Button(s)


I am developing a web project in asp.net using vb and want to allow the user to navigate through my enrollment process using the Browser's Back and Forward buttons. Is this possible?


Thank you in advance.

disable back button of browser so that a user can't go on previous pages after signout


hi All

i am working in asp.net 2.0 with vb.net.

i want to disable back button of browser so that a user can't go on previous pages after pressing signout hyperlink.

i applied this code in load  event of page that i want to disable on back button of browser but it is not ing please help me in detail as soon as possible.





"Pragma", "no-cache")





Disable Back and Forward button in the IE and Mozilla browser


Hi every body

I want to disable back and forward button in the IE and Mozilla when my application (which is a WPF, XBAP project in the .Net 4.0) is deployed in a browser.

The main form is a System.Windows.Window. Please help me how can id do that.


Disable Browser Back Button Using Javascript ASP.NET


 Hi... Am using following script, disable back browser, it works well, only in Chrome, if i try ie it says .. Webpage has expired,   any simple method is there? but it should suitable for browsers !

<script type = "text/javascript" >
    function disableBackButton() {
    setTimeout("disableBackButton()", 0);

<body onunload="disableBackButton()">
Protected Overloads Overrides Sub OnPreRender(ByVal e As EventArgs)
        Dim strDisAbleBackButton As String
        strDisAbleBackButton = ""
        ClientScript.RegisterClientScriptBlock(Me.Page.[GetType](), "clientScript", strDisAbleBackButton)
End Sub

After logout is done check is made so that the browser back button does not retun to the last visite


Why this code not working.I want after logout is done check  the browser back button does not retun to the last visited page.

please help me.

 <script language = "javascript" type = "text/javascript">

         -- After LOGOUT is done,check is made so that the browser back button
         does not retun to the last visited page.
         -- The below function is called in OnClientClick of Login button
         function SetLogoutCookie(value) {
             var exdate = new Date();
             exdate.setDate(exdate.getDate() + 1);
             var expires = "; expires=" + exdate.toGMTString();
             document.cookie = "logout=" + value + expires + "; path=/";

On browser back button click again login in Application problem



In my project I am using the FormsAuthenticationTicket and maintain session when any user login in the application. On logout I am expire the seesion using Session.Abandon (); but when I click on the browser back button after logout it again login in the application. I want after logout if any user clicks on the browser back button it do not again login in the application it redirect it on login page. But I do not how it could be possible.


Below is my code


protected void btnLogon_Click(object sender, EventArgs e)


            propertyStore.BusinessLayer.Users objUser = new propertyStore.BusinessLayer.Users();

            if (objUser.IsAuthentic(txtUserName.Text, txtPassword.Text))



                FormsAuthenticationTicket ticket = new FormsAuthenticationTicket(


Reg: Turn on more accessible mode & Skip to main content link message on Infopath2007 browser form



I have a infopath 2007 browser enabled form with c# code behind . The Infopath form is embeded\hosted in to a custom layouts page (.aspx) on MOSS 2007. The issue is when users use keyboard to fill the form, they often use <TAB> & <Enter> keys. So when they are using the tabbing at one location in the form, I have a "Contact selector" field, I enter a name & then hit <TAB> key the focus now comes to "name cheker" I then hit <Enter> key, I hit <TAB> again, the focus now comes to a button named "Accept", I hit <Enter> key & a filed below is populated with the values from user profile service. Now when I hit <TAB> I expect the focus should now come to that automatically populated field below the "Contact selctor". Because Infopath assings the tab order by default form top to bottom & left to right and I havent changed that default tab order.   

But, the focus moves to top of the webpage with a clickable link to "Turn on more accessible mode" I hit tab one more time & the link on top changes to "Skip to main content". This bheaviour does not seem to be happning in other form controls when they hit <Tab>, <Enter>. There are couple of areas on the infopath form where I have such a controls (layed ou

Attachment upload error on browser based InfoPath form



I am having an interesting problem with browser based InfoPath forms in SharePoint 2007.  For some reason the file attachment control is not working any more.  It was working fine in July, but now it will not allow file attachments over a few kb.  I tried a 34KB file and I get the error below, a 2KB file works fine.

Unable to connect to SQL Server session database. The connection string (server='SPDB', database='SharedServices1_DB') was returned by an instance of the IPartitionResolver type 'Microsoft.Office.Server.Administration.SqlSessionStateResolver, Microsoft.Office.Server, Version=, Culture=neutral, PublicKeyToken=71e9bce111e9429c'.   at System.Web.SessionState.SqlSessionStateStore.ThrowSqlConnectionException(SqlConnection conn, Exception e)
   at System.Web.SessionState.SqlSessionStateStore.HandleInsertException(SqlConnection conn, Exception e, Boolean newItem, String id)
   at System.Web.SessionState.SqlSessionStateStore.SetAndReleaseItemExclusive(HttpContext context, String id, SessionStateStoreData item, Object lockId, Boolean newItem)
   at System.Web.SessionState.SessionStateModule.OnReleaseState(Object source, EventArgs eventArgs)
   at System.Web.HttpApplication.SyncEven

Issue in Infopath 2007 browser form - cascading dropdown using owssvr.dll filter view


Referring the below link, I created a cascading dropdown. The parent dropdown has sharepoint list as datasource and the child dropdown has xml datasource that points to owssvr.dll filter view. The cascading drop down works fine in preview but throws error after publishing as admin approved form - "form cannot run the specified query" exception when trying to execute xml datasource i.e., when a value is selected in parent dropdown. The security is 'Full Trust". In the event viewer the error message states "401 unauthorised" for the user a/c. the xml data source is an approved udcx file and in central admin, have enabled cross domain for infopath service. I have tried different solution provided in tech forums but issue still exists. Not sure whether Im missing something. Can someone guide me in fixing this issue?

Link Reffered:



ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend