How to make a simple popup box in Visual C#?

neuromancer picture neuromancer · Nov 27, 2009 · Viewed 256k times · Source

When I click a button, I want a box to popup on the screen and display a simple message. Nothing fancy really. How would I do that?

Answer

Alex J picture Alex J · Nov 27, 2009
System.Windows.Forms.MessageBox.Show("My message here");

Make sure the System.Windows.Forms assembly is referenced your project.