From 1674dcc94f01058aea0d6cf5d5e8f828a31b969c Mon Sep 17 00:00:00 2001 From: ​ Date: Thu, 1 Jan 1970 00:00:00 +0000 Subject: joke & punch line --- joke_and_punch_line/Joke and Punch Line/Form1.cs | 45 ++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 joke_and_punch_line/Joke and Punch Line/Form1.cs (limited to 'joke_and_punch_line/Joke and Punch Line/Form1.cs') diff --git a/joke_and_punch_line/Joke and Punch Line/Form1.cs b/joke_and_punch_line/Joke and Punch Line/Form1.cs new file mode 100644 index 0000000..b7b23a6 --- /dev/null +++ b/joke_and_punch_line/Joke and Punch Line/Form1.cs @@ -0,0 +1,45 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace Joke_and_Punch_Line +{ + public partial class jokeAndPunchLine : Form + { + public jokeAndPunchLine() + { + InitializeComponent(); + } + + private void setupButton_Click(object sender, EventArgs e) + { + jokeLabel.Text = "Why did the computer go to the doctor?"; + punchLineButton.Visible = true; + setupButton.Visible = false; + } + private void punchLineButton_Click(object sender, EventArgs e) + { + jokeLabel.Text = "It had a virus!"; + punchLineButton.Visible = false; + setupButton.Visible = true; + } + + private void clearButton_Click(object sender, EventArgs e) + { + jokeLabel.Text = "?"; + setupButton.Visible = true; + punchLineButton.Visible = false; + } + + private void exitButton_Click(object sender, EventArgs e) + { + this.Close(); + } + } +} -- cgit 1.4.1