In my example
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
<asp:Timer ID="Timer1" runat="server" Interval="10000" ontick="Timer1_Tick">
</asp:Timer>
</ContentTemplate>
</asp:UpdatePanel>
the timer tick time is 10000 seconds for every 10 seconds page will be loaded again and again.....
but
the question is for every 10 seconds page is loaded as synchronus or asynchrouns?
my code behind is
protected void Page_Load(object sender, EventArgs e)
{
if (Page.IsAsync)
{
Label2.Text = "page is Asynchrous processing...."; // for every aschronus request
}
else
{
Label2.Text = "page is Sychronus processing..."; // first time request only.
}
}
protected void Timer1_Tick(object sender, EventArgs e)
{
// for every 10 seconds tick even will be fired
if (ScriptManager1.IsInAsyncPostBack == true)
{
Label1.Text = DateTime.Now.ToString();
}
}
protected void Button1_Click(object sender, EventArgs e)
{
Label3.Text = "to cause postback to the server";
}
but Lable2.Text always shows
page is Sychronus processing... only.and if i click on button(implictly postback) within 10 seconds it has to show Lable2.Text is Synchronus page porcessing
-------but not working.
Regards,
Kasi babu