PlaceHolder Disappears on Page PostBack

  • Thread starter Thread starter Vishal Gupta
  • Start date Start date
V

Vishal Gupta

Hi all,

I have a placeholder control on an ASPX page. I
dynamically add a few button control and label control to the placeholder
from
code - all is well with the world. But on post back the
control disappears from the placeholder. Am I missing
something here
Please help

Vishal Gupta
 
i think i found a better solution.. We can do in Page_init Method...

ASP.NET pages automatically bind page events to methods that have the name
Page_event. This automatic binding is configured by the AutoEventWireup
attribute in the @ Page directive, which is set to true by default. If you
set AutoEventWireup to false, the page does not automatically search for
methods that use the Page_event naming convention.
http://msdn2.microsoft.com/en-us/library/6w2tb12s.aspx
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top