« Pacers Game | Main | New features in VS Whidbey »
December 20, 2003
IsNumeric in .NET
In CPT 355 we've always shown students to us the try/catch method. I didn't even know that the TryParse method exists. Probably because TryParse isn't supported in the compact framework. Looks like exception handling really does carry quite an overhead. Makes sense why the guidelines state to not use exception handling for normal flow control too. But the char and regex methods seem to fragile, so I guess I'd still go with an exception handling method.
Here is a good article on the various techniques a developer can use to implement IsNumeric in C#:
http://aspalliance.com/articleViewer.aspx?aId=80&pId=2
[CJCraft's Blog]
Posted by mikel at December 20, 2003 02:16 PM
Comments
Post a comment
Thanks for signing in, . Now you can comment. (sign out)
(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)