updatepanel and variable request error

Last post 11-08-2007 2:17 PM by koolhaus. 2 replies.

Sort Posts:

  • updatepanel and variable request error

    11-08-2007, 10:51 AM
    • Member
      point Member
    • koolhaus
    • Member since 11-08-2007, 10:42 AM
    • Posts 2

    I am running into an issue on a page.  I am trying to use an updatepanel.  Everything works as it should until I comment out my test code that is setting the vaules of some textboxes and have them be filled by a simple Request.

     The updatepanel has a button that resides outside of it that is defined as an asynpostback trigger.  it then dynamically generates a bunch of fileuploaders based on a number supplied.

    To debug things further i added a simple command to the button that no longer works when i have requests.  a simple text setting for a label does not go through, so my guess is the button event is somehow being ignored, but why?

     
    simply put...

    this line:

    t_report.Text = mydb.get_fmdesc(Request["fmtype"]);

     as opposed to:

    t_report.Text = mydb.get_fmdesc("S");

     
    causes the breakage of the updatepanel asyncpostback

     

     

    last note:  removing the trigger for the updatepanel [and as a result refreshing the whole page] works just fine, but is obviously not what is desired.

     

     

    Any feedback would be greatly appreciated.

     

    Thanks


     

  • Re: updatepanel and variable request error

    11-08-2007, 2:04 PM
    • Star
      8,978 point Star
    • dwhite
    • Member since 02-08-2007, 2:25 PM
    • Bristol, CT
    • Posts 1,422

    Not sure of your issue without seeing your code.  You may want to check out http://www.asp.net/AJAX/Documentation/Live/overview/UpdatePanelOverview.aspx for how to use the UpdatePanel and Triggers.

    Also, make sure AJAX is setup correctly in your app: http://blogs.visoftinc.com/archive/2007/09/23/asp.net-ajax--updatepanel-not-working--common-problems.aspx

    -Damien

    Visoft, Inc - Home | Blogs

    Latest Blog Post: Silverlight DataBinding Bug
  • Re: updatepanel and variable request error

    11-08-2007, 2:17 PM
    Answer
    • Member
      point Member
    • koolhaus
    • Member since 11-08-2007, 10:42 AM
    • Posts 2

     Thank you for the quick reply.  I was able to find a fix, though it still makes little sense.  I moved the variable setting via a Request to a conditional on pageload for postback or not [so it would only occur the first time].  This solved my problem, but I see no reason why it would.

Page 1 of 1 (3 items)