Where should i put a timer that call a method every 5 minutes ?
i put it in MasterPage but call every time that i load a page that use this MasterPage but i want to call just every 5 minutes
i use this code in MasterPage
<body>
<form id="form1" runat="server">
<div id="divNews" class="news" runat="server"></div>
<asp:ScriptManager ID="ScriptManager1" runat="server" />
<asp:UpdatePanel runat="server" id="UpdatePanel" updatemode="Conditional">
<ContentTemplate>
<div class="divTit">
<table style=" width:100%">
<tr style=" width:100%; text-align:right;">
<td style=" width:100%;"><!--Inbox-->
<asp:LinkButton CssClass="lblMainMenu1" runat="server" ID="lblInbox" OnClick="inbox_Click"></asp:LinkButton>
<asp:Label Text="Inbox :" runat="server" CssClass="lblMainMenu2"></asp:Label>
</td>
</tr>
</table>
</div>
</ContentTemplate>
<Triggers>
<asp:AsyncPostBackTrigger controlid="timer" EventName="Tick" />
</Triggers>
</asp:UpdatePanel>
<asp:Timer Interval="1" ID="timer" OnTick="timer_Tick" runat="server"></asp:Timer>
<div id="body" class="divBody">
<asp:ContentPlaceHolder id="head" runat="server"></asp:ContentPlaceHolder>
<asp:ContentPlaceHolder id="contentMain" runat="server"></asp:ContentPlaceHolder>
</div>
</form>
</body>