Page_Load being fired twice

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Nimrod Cohen (nim_co_at_hotmail.com)
Date: 05/27/04


Date: Thu, 27 May 2004 09:31:01 -0700

Hi,

During the page_load of my Aspx page "http://myMachine/MyWebApp/Quote.aspx" , i write to the response an html that embeds a form with the action pointing out to the same aspx page
i.e
Response.Write( "<html><head></head><body><form action="http://myMachine/MyWebApp/Quote.aspx" name="QuoteForm" method="POST"><input type="hidden" name="response_supplier_id" value="13"/>
...
</form></body></html>" );

what happens is that my page_load function is being fired twice, once with all the parameters in the Request.Form arriving as expected ( the first occurance is a POST call ), the second time i get an unwanted "GET" call with no parameters in the Request.Form.

I've checked and verified that the AutoEventWireup=false, and no event handler duplication has been introduced

could anyone point out of this mess ?