Having trouble with getting messagebox to work correctly

Const Message as String = "Please enter a number"

Posted 02 July 2008 - 12:07 AM

I've been stuck on this awhile...If a letter is placed in the numberRegistered text box then a messagebox is suppose to come up telling the user to enter a number. Here the code I have as of right now...

Nope, that didn't work either I believe the problem is between the
'Const Message as string' and getting the MessageBox.Show to work with it..Way this is I put in a number and the messagebox comes up telling me to enter one...lmao It should only do that when a letter is put in.

Re: Const Message as String = "Please enter a number"

Just can't leave this one, so a last suggest.
Insert a breakpoint at the point suggested in the code below.

A breakpoint stops the code at runtime, allowing it to step through to further aid debugging.
To insert a breakpoint click on the line, right click-> Breakpoint -> Insert breakpoint

Run the code, enter some test data and click the button, the program will break at that line.
Now by pressing F8 or Shift-F8 (This key combination ignore functions and subroutines.) to step through the code.

Examine the content of variable, either by highlighting the variable and hover the mouse over it.
Or double-left click on the variable to highlight it, rightclick add watch.
This will open a window titled Watches, and it will list all of the variable being watched.

Keep stepping though the code, nothing path / sequence the program takes.