Why does ShowDialog() show old message?
I entered a "test message" for my ShowDialog, then changed it to a new message. But it is still showing the "test message"
New Code
private void addButton_Click(object sender, EventArgs e)
{
//MessageBox.Show("Debugging Add Test Button", "My Test Application",
//MessageBoxButtons.OKCancel, MessageBoxIcon.Asterisk);
//Display Add Alarm form
AlarmForm alarmForm = new AlarmForm();
//Display alarmForm instance, assgn the results to a Dialog result
DialogResult dialogResult = alarmForm.ShowDialog();
//Check return value, and extract data
if (dialogResult == DialogResult.OK) // Add Alarm
{
//Extract Alarm information from the Form using the accessor
Alarm alarm = alarmForm.Alarm;
//Add the alarm object to our list
_alarms.Add(alarm);
//Update the Listbox
refreshAlarmList();
}
}
Old Code
private void addButton_Click(object sender, EventArgs e)
{
MessageBox.Show("Debugging Add Button", "My Application",
MessageBoxButtons.OKCancel, MessageBoxIcon.Asterisk);
}
Any ideas on what is causing this? I have tried removing the code, adding in the new message, and commenting it out.