|
-
Nov 30th, 2010, 05:38 PM
#25
Re: Random Number Generator - Store generated numbers
 Originally Posted by incidentals
at this point he has not tested for alpha inputs so his test will work fine numbers as literals or some kind of numeric datatype all test the same in textboxes
the empty and alphabetic tests should prehaps happen before the simplistic text1.text>text2.text expressions though for completness
the kids getting there though...
but it is always good to restart your solution as you are able to utilise new concepts that make for a more robust and/or faster solution, sometimes even prettier and smaller/easier to read.
"programming is more of an art than a science"
If you are saying that as long as the user inputs only numbers the code will work, then yes. We all know that users never make mistakes 
@noob - look at the code I posted. TryParse is something you should search for here http://msdn.microsoft.com/en-us/libr...VS.100%29.aspx.
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
|