秒钟倒计时
新手想做一个秒钟倒计时 求代码!!用Timer 控件来控制倒计时开始!
2013-05-09 13:42
程序代码:
using System;
using System.Collections.Generic;
using using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
xianshi();
}
public static int miao = 60;
public void xianshi()
{
textBox1.Text = miao.ToString();
}
private void timer1_Tick(object sender, EventArgs e)
{
miao -= 1;
xianshi();
}
private void button1_Click(object sender, EventArgs e)
{
timer1.Enabled = true;
}
}
}
2013-05-10 15:41
2013-05-10 15:57
2013-05-11 20:48
2013-05-13 16:41