How will you identify whether the page is post backed or not?

Using “IsPostBack” property, you will identify whether the page is post backed or not.

Example

protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
//code that runs first time not execute when page is post back.
}
}

Leave a Reply

Your email address will not be published. Required fields are marked *

nineteen − 3 =