Message box results....
-
How do I control a messageboxes results? I know of the msgboxresult.yes/no/ok etc. But I am missing something because when I use this no matter what the result is it still runs the same code when it shouldnt. If someone could please give me a quick example on how to use messageboxes and have different things happen depending on the msgboxresult I would really appreciate it. Thank you...
-
How do I control a messageboxes results? I know of the msgboxresult.yes/no/ok etc. But I am missing something because when I use this no matter what the result is it still runs the same code when it shouldnt. If someone could please give me a quick example on how to use messageboxes and have different things happen depending on the msgboxresult I would really appreciate it. Thank you...
-
How do I control a messageboxes results? I know of the msgboxresult.yes/no/ok etc. But I am missing something because when I use this no matter what the result is it still runs the same code when it shouldnt. If someone could please give me a quick example on how to use messageboxes and have different things happen depending on the msgboxresult I would really appreciate it. Thank you...
you can try this
If MessageBox.Show("Do you want Exit?", "titleBar", MessageBoxButtons.YesNo, MessageBoxIcon.Question) = DialogResult.Yes Then
'quiting the Application
Else
'Dont Quit
End IfVuyiswa Maseko
-
How do I control a messageboxes results? I know of the msgboxresult.yes/no/ok etc. But I am missing something because when I use this no matter what the result is it still runs the same code when it shouldnt. If someone could please give me a quick example on how to use messageboxes and have different things happen depending on the msgboxresult I would really appreciate it. Thank you...
Dim msgResult As MsgBoxResult = MsgBox("Do you want to SAVE this record?", MsgBoxStyle.YesNoCancel, "DATA HAS CHANGED") Select Case msgResult Case MsgBoxResult.Yes ' Save Data Case MsgBoxResult.No ' Clear the form Case MsgBoxResult.Cancel ' Do nothing End Select
Tom Garth Developer R. L. Nelson and Associates, Inc., Virginia