|
| Web News |

Supercomputers Key To Improving Hurricane... Scientists at the National Oceanic & Atmospheric Administration are hoping two new supercomputers will help them make more accurate hurricane predictions so people have more warning and a better chance to get to safety before a storm hits. The IBM supercomputers...
Germany seeks common E.U. rules on violent... Violent video games could be outlawed across the European Union, following calls for a clampdown among E.U. justice ministers this week. Germany, which took over the six-month rotating presidency of the union at...
German Google site hobbled by Internet mix-up Internet search engine giant Google said its German website was waylaid for two hours Tuesday because its address was mistakenly reassigned. The temporary takeover of the site just after midnight was not the result of a hacker attack, a spokesman for Google in the...
Siemens Plans Automotive IPO, Buys PLM... Ahead of its shareholders Meeting Jan. 25 here, Siemens announced two moves intended to improve its focus on its core business: The German conglomerate intends to spin off its Automotive electronics branch Siemens...
Electronics: Chips Everywhere Over the last 30 or so years, British entrepreneur Hermann Hauser has backed about 100 ideas, including three companies that have hit the billion-dollar mark. Plastic Logic, a Cambridge-based outfit launched six years ago, now seems to be shifting into high gear.
|
 | |
|
02.01.07
A Universal Data Type Checker
By Mads Kristensen
In many different scenarios we need to check if a string can be converted into an integer e.g.
This could be when we work with query strings and need to check if they match a certain data type.
In VB.NET you can use the IsNumeric and IsDate functions, but that's about it.
You are left to your own data type checking logic the rest of the
time.
It would be cool if we could have a method that could check all data types that is represented by strings such as integers, guids, booleans etc.
Here is a method that does just that.
It can check all the string based types and also enums.
Cost Effective Website and Network Monitoring IPCheck Server Monitor - Free Download |
|
Comments
About the Author: Mads Kristensen currently works as a Senior Developer at Traceworks located
in Copenhagen, Denmark. Mads graduated from Copenhagen Technical Academy with a multimedia degree in
2003, but has been a professional developer since 2000. His main focus is on ASP.NET but is responsible for Winforms, Windows- and
web services in his daily work as well. A true .NET developer with great passion for the simple solution.
http://www.madskristensen.dk/
|