vs中有没有倒计时的控件,要是没有,怎么样实现像QQ游戏里面的倒计时

解决方案 »

  1.   

    自己写一个不就可以了..    用timer控件就可以了啊。。  把时间设置成1000毫秒。。~  就得啦。~
      

  2.   

    不是所有东西都有现成的控件的,timer可以计时就够了
      

  3.   

    用timer控件。。并且在 timer里写代码就可以了
      

  4.   

    WebForm中javaScript就可以实现
    WinForm中用Timer控件
      

  5.   

    timer控件就可以实现,interval可以设置成你触发时间间隔,比如说1000,就是一秒
    你先定义一个倒计时的时间,比如说10分钟,然后记录当前时间,每一秒钟时间就减1,然后直到为零,就倒计时结束了
      

  6.   

    timer够了
    变通一下,用减法
      

  7.   

    timer控件,具体使用方法可以参考下MSDN,挺详细的,
      

  8.   


    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Text;
    using System.Windows.Forms;using System.Timers;namespace Time
    {
        public partial class Form1 : Form
        {
            private int second=0;        public Form1()
            {
                InitializeComponent();
            }        private void button1_Click(object sender, EventArgs e)
            {
                timer1.Enabled = true;
                timer1.Interval = 1000;
                second =Convert .ToInt32(textBox1.Text)*60;
            }        private void timer1_Tick(object sender, EventArgs e)
            {
                if (second >= 0)
                {
                    label1.Text = second.ToString();
                    second--;
                    if (second == 5)
                    {
                        MessageBox.Show("时间到.请交试卷");
                    }               
                }
            }
        }
    }
      

  9.   

    只知道有个Timer可以考虑从它下手