請問一下大家...我想要點擊時可以切換button的圖片...但是
private void button3_Click(object sender, EventArgs e)
{
if (button2.BackgroundImage == Properties.Resources.英文開1)
{
button2.BackgroundImage = Properties.Resources.英文關1;
}
else
{
button2.BackgroundImage = Properties.Resources.英文開1;
}
}//這樣是不行的...為何??
private void button2_Click(object sender, EventArgs e)
{
if (button2.Text == "start") {
button2.Text = "end";
}
else
{
button2.Text = "start";
}
}//這樣卻是可以的??