Page_Init use
In most of code behind pages i see the constructor with page_int initializer e.g.web page is ProjectEntry.aspx then in ProjectEntry.aspx.cs
public ProjectEntry()
{
Page.Init += new System.EventHandler(Page_Init);
}
private void Page_Load(object sender, System.EventArgs e)
{
// Put user code to initialize the page here
}
private void Page_Init(object sender, EventArgs e)
{
InitializeComponent();
}
What is its use and its advantage ?
is it a good practice or bad to use it
|