In VB.Net there is a useful function to check numeric data which is not available in C#. Here I m showing the IsNumeric function for c# which can be used to achieve the same result.
bool IsNumeric(string strValue)
{
try
{
double doub = double.Parse(strValue);
return true;
}
catch
{
return false;
}
}
Cheers
Samitha
bool IsNumeric(string strValue)
{
try
{
double doub = double.Parse(strValue);
return true;
}
catch
{
return false;
}
}
Cheers
Samitha
No comments:
Post a Comment