Beispiel #1
0
        private void buttonOpen_Click(object sender, EventArgs e)
        {
            openFileDialog.InitialDirectory = selectedFolder;
            openFileDialog.Filter           = "Text files (*.txt) | *.txt | All files (*.*) | *.*";
            openFileDialog.FileName         = textBoxExcuseDescription.Text + ".txt";
            DialogResult result = openFileDialog.ShowDialog();

            if (result == DialogResult.OK)
            {
                currentExcuse = new Excuse(openFileDialog.FileName);
            }
            UpdateForm(false);
        }
Beispiel #2
0
 private void buttonRandom_Click(object sender, EventArgs e)
 {
     currentExcuse = new Excuse(random, selectedFolder);
     UpdateForm(false);
 }