L*兰兰*  

 

 

namespace 排球计分程序
{
public partial class Form3 : Form
{
public Form3()
{
InitializeComponent();
}

private void Form3_Load(object sender, EventArgs e)
{
textBox3.Enabled = false;
button2.Enabled = false;
}

private void textBox1_TextChanged(object sender, EventArgs e)
{
if (textBox1.Text == "")
{
button2.Enabled = false;
}
}

private void button2_Click(object sender, EventArgs e)
{
textBox3.Text = "比赛结果为:" + textBox1.Text + ":" + textBox2.Text + "=25:24 " + textBox1.Text + "胜利" + textBox2.Text + "惜败";
}

private void button3_Click(object sender, EventArgs e)
{
textBox1.Text = "";
textBox2.Text = "";
textBox3.Text = "";
button2.Enabled = false;
}

private void textBox2_TextChanged(object sender, EventArgs e)
{
if (textBox1.Text != "" && textBox2.Text != "")
{
button2.Enabled = true;
}
else
{
button2.Enabled = false;
}
}

private void textBox3_TextChanged(object sender, EventArgs e)
{

}

private void button1_Click(object sender, EventArgs e)
{
this.Close();
首页 s = new 首页();
s.Show();
}
}

 

posted on 2016-12-24 22:42  L*兰兰*  阅读(85)  评论(0编辑  收藏  举报