|
-
Apr 14th, 2003, 04:37 PM
#1
Thread Starter
Fanatic Member
error
Hi Guys,
I am trying to run my first C# program. Placed a button on the windows form.
Here is the code for the button
private void button1_Click(object sender, System.EventArgs e)
{
messagebox.show("Hello there!");
}
But as the program is run The error is: The type or namespace name 'messagebox' could not be found (are you missing a using directive or an assembly reference?)
Any thoughts pls?
Thanks
-
Apr 14th, 2003, 04:45 PM
#2
PowerPoster
C# is case-sensitive, therfore, messagebox does not exist in any of the reference assemblies. Use this:
Code:
MessageBox.Show("Hello World");
Have fun.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|