想要在我的网页上显示秒表 [英] Want to dispaly a stop watch on my web page

查看:114
本文介绍了想要在我的网页上显示秒表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

朋友们,
我想在我的网页上显示秒表,我的页面上显示一个问题和四个选项,例如我有问题,为了解决这些问题,我们有时间证明学生必须在一定时间内完成考试,所以为此,我想在页面上显示一个计时器,计时器应以mm:ss格式显示剩余时间.

在此先感谢.......


Hi friends,
i want to display a stop watch in my web page,i have a page that display a question and four options, like this i have questions, for solving those question we have a time constriant that student has to finish his exam within the time, so for that i want to display a timer on the page that timer should display remaining time in mm:ss format.

Thanks in Advance.......


It is displaying error like "DDateStampLabel does not exist in context"
Help me to solve this error...

<pre lang="xml">&lt;asp:ScriptManager ID=&quot;ScriptManager1&quot; runat=&quot;server&quot; /&gt;
        &lt;asp:Timer runat=&quot;server&quot; ID=&quot;UpdateTimer&quot; Interval=&quot;5000&quot; OnTick=&quot;UpdateTimer_Tick&quot; /&gt;
        &lt;asp:UpdatePanel runat=&quot;server&quot; ID=&quot;TimedPanel&quot; UpdateMode=&quot;Conditional&quot;&gt;
            &lt;Triggers&gt;
                &lt;asp:AsyncPostBackTrigger ControlID=&quot;UpdateTimer&quot; EventName=&quot;Tick&quot; /&gt;
            &lt;/Triggers&gt;
            &lt;ContentTemplate&gt;
                &lt;asp:Label runat=&quot;server&quot; ID=&quot;DateStampLabel&quot; /&gt;
            &lt;/ContentTemplate&gt;
        &lt;/asp:UpdatePanel&gt;</pre>


Code Behind File:

 DateStampLabel.Text = DateTime.Now.Tostring()

推荐答案


您可以使用javascript秒表

JavaScript秒表 [
Hi
you can use javascript stop watch

JavaScript Stopwatch[^]

Hope this will help :)

Thanks
Vinod Satapara


显示错误,例如"DDateStampLabel在上下文中不存在"
帮助我解决此错误...

It is displaying error like "DDateStampLabel does not exist in context"
Help me to solve this error...

<asp:ScriptManager ID="ScriptManager1" runat="server" />
        <asp:Timer runat="server" ID="UpdateTimer" Interval="5000" OnTick="UpdateTimer_Tick" />
        <asp:UpdatePanel runat="server" ID="TimedPanel" UpdateMode="Conditional">
            <Triggers>
                <asp:AsyncPostBackTrigger ControlID="UpdateTimer" EventName="Tick" />
            </Triggers>
            <ContentTemplate>
                <asp:Label runat="server" ID="DateStampLabel" />
            </ContentTemplate>
        </asp:UpdatePanel>




文件后面的代码:

DateStampLabel.Text = DateTime.Now.Tostring()




Code Behind File:

DateStampLabel.Text = DateTime.Now.Tostring()


这篇关于想要在我的网页上显示秒表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆