using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication7
{
public partial class Form1 : Form
{
private int second = 0;
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
second = Convert.ToInt32(textBox1.Text);
}
private void timer1_Tick(object sender, EventArgs e)
{
if (second > 0)
{
label1.Text = second.ToString();
--second;
}
}
}
}
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication7
{
public partial class Form1 : Form
{
private int second = 0;
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
second = Convert.ToInt32(textBox1.Text);
}
private void timer1_Tick(object sender, EventArgs e)
{
if (second > 0)
{
label1.Text = second.ToString();
--second;
}
}
}
}
