I have a timer on my parent master page that checks for certain events and updates controls that I want through an updatePanel.
I have numerous child pages that inherit from the master page.
I get the desired effect of the timer checking for some event and updating the controls I specified.
The undesired effect is the timer will go through the selected(In View) child page --- page life cycle.
So if I have a code in my Page_Init or Page_Load event handlers whatever is in them gets executed.
Doesn't render the html because it is a call back and only updates the control I specified like I wanted but, It seems unnessary that It goes through the page lifecycle of the child page.
I m developing a Instant Messenger in our web application using asp .net and c# wherein users are allowed to chat like gmail. I have one timer on master page that calls ajax function and updates its status as online or offline in database at 30 seconds time interval. And also checks any new message is arrived for the user. But it causes child page life cycle to execute at every call and executes page_ load event.
How can i avoid child page life cycle to execute?
Question is, How Can I stop the timer from firing my child page event handlers??
Need solution urgently.
Thanks in advance.
<asp:Timer ID="TimerToCheckOnline" OnTick="TimerToCheckOnline_Tick" runat="server" Interval="30000" />
<asp:UpdatePanel ID="FieldUpdatePanel1" UpdateMode="Conditional" runat="server">
<asp:AsyncPostBackTrigger ControlID="TimerToCheckOnline" />
protected void TimerToCheckOnline_Tick(object sender, EventArgs e)