I use this function found on the stackoverflow site to check whether a string is a number:

return System.Text.RegularExpressions.Regex.IsMatch
         (TextValue, @"^-?\d+([\.]{1}\d*)?$");

 It recognizes integers and decimals. However, it fails on comma separators.

 

More tips at http://c-sharpe.blogspot.com/