Hi Marvin,
I'm a VB programmer, learning C#. How does one do the equivalent of a
"msgbox" (from Visual Basic) in C#? Is there something like this:
System.Forms.MessageBox("Hello World");
Thanks,
Marvin
You almost guessed it alreadyt:
System.Windows.Forms.MessageBox.Show("Hello World");
(don't forget the semicolon
Btw., don't worry - you won't have to retype that lengthy namespace, just add
using System.Windows.Forms;
at the top of your .cs file, if the "New Project" wizard did not do that for
you already.
Then, just use e.g.
MessageBox.Show("Hello World");
(There's lots of alternatives btw, if you are using Visual Studio, try opening
the curling brace after typing "Show" and srcoll through them with cursor up
and down)
Have fun with C#!
Regards,
Gilles.