.NET Framework - Yes/No dialog box

Asked By Mark on 26-May-08 02:37 PM
I am new to C# but know MFC C++. I am looking for api for launching a yes/no
dialog box which returns a value that can be used for farther processing.


Peter Duniho replied on 26-May-08 02:43 PM
kimiraikkonen replied on 27-May-08 11:04 PM
MessageBox object is what you're looking for. For more dialog boxes
such as Open/Save Dialogs, look at your toolbox in VS IDE.

A sample for determining MessageBox result:

if (MessageBox.Show("are you sure?","Sure?",MessageBoxButtons.YesNo)
=3D=3D DialogResult.Yes)
MessageBox.Show("Ok clicked");
MessageBox.Show("No clicked");

Hope this helps,

Onur G=FCzel