Page-load executing twice

  • Thread starter Thread starter mart
  • Start date Start date
M

mart

I am experiencing a weird problem with some buttons on my
webpage. The page_load is executing twice when a button is
clicked.

If I replace the button for a Linkbutton the page_load
only loads once.

I've set the Autoeventwireup to false.

Could it be a framework problem ? On other computers the
bug is difficult to reproduce but on mine the problem is
constant. I am using framework version 1.0 with SP2.

Thanks for your help
 
mart hi,

does it happaned on plain form with just one button? its probebly
connected to something in your code, can you post it ?

Natty Gur, CTO
Dao2Com Ltd.
34th Elkalay st. Raanana
Israel , 43000
Phone Numbers:
Office: +972-(0)9-7740261
Fax: +972-(0)9-7740261
Mobile: +972-(0)58-888377
 
mart said:
I am experiencing a weird problem with some buttons on my
webpage. The page_load is executing twice when a button is
clicked.

If I replace the button for a Linkbutton the page_load
only loads once.

I've set the Autoeventwireup to false.

Could it be a framework problem ? On other computers the
bug is difficult to reproduce but on mine the problem is
constant. I am using framework version 1.0 with SP2.

Thanks for your help


The way I understand it, the page posts back to the server when you
press the button (1st page load) and then posts again to show the
changes that occured after the button click executed (2nd page load).
You could use the Page.IsPostBack property to only run the Page_Load
event when the page first loads. Hope this helps.

Neil
 
Back
Top