Click here to Skip to main content
Click here to Skip to main content
Articles » Languages » C# » General » Downloads
 

Web Timer Control

By , 7 Oct 2008
 
<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="ManualStart.aspx.cs" Inherits="ManualStart"  Title="Manual Start" %>
<%@ Register Namespace="CodeControls" TagPrefix="cc" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
   <h2>Manual Start</h2>
    <div>    
    <table style="color:Green;font-weight:bold">
    <tr>
    <td colspan="2" style="text-decoration:underline">Timer Settings</td>    
    </tr>
    <tr>
    <td align="right"> AutoStart:</td><td><asp:Label ID="lbAutoStart" runat="server"/></td>    
    </tr>
    
     <tr>
    <td align="right"> PostBack On TimeOut:</td><td><asp:Label ID="lbPostBack" runat="server"/></td>    
    </tr>
    
    <tr>
    <td align="right"> Disable Mouse Right Click: </td><td><asp:Label ID="lbMouseClick" runat="server"/></td>    
    </tr>
    
    <tr>
     <td align="right"> Sync Clock With Server: </td><td><asp:Label ID="lbSyncTimer" runat="server"/></td>    
    </tr>
    </table>
    
    <br />
    <br />
     <cc:Timer ID="Timer1" runat="server" Font-Bold="True" Font-Names="Verdana" Font-Size="48px" ForeColor="#FF8000"
     Interval="5" IsAutoStart="False" DisableRightClick="False" DoPostBackOnTimeOut="False" ServerSideTimeSynchronize="True" TimeOut="24" 
     OnIntervalReached="Timer1_IntervalReached" OnTimeOutOccurred="Timer1_TimeOutOccurred"
     ></cc:Timer><br />
        <br />
        &nbsp;<br />
        <br />
        <asp:Button ID="Button2" runat="server" OnClick="Button2_Click" Text="Start Timer" />
        <br />
        <br />
        <asp:Button ID="Button1" runat="server" Text="Create PostBack" /></div>
</asp:Content>

By viewing downloads associated with this article you agree to the Terms of use and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU General Public License (GPLv3)

About the Author

Prem Rajadattan
United States United States
Member

Permalink | Advertise | Privacy | Mobile
Web04 | 2.6.130523.1 | Last Updated 7 Oct 2008
Article Copyright 2008 by Prem Rajadattan
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid