One little fix for my script (just for those who like to use it in future): need check for empty string.
Final:
Code:
// check if string is a valid number
//
bool IsNumeric(char[] Str)
{
static Regex regex;
if (regex == null)
regex = new Regex("^(((\\+|-)?\\d+(\\.\\d+)?)|((\\+|-)?\\.\\d+))(e(\\+|-)\\d+)?$", PCRE_CASELESS);
if (strlen(Str) == 0) return (false);
return (regex.Match(Str) > 0);
}
__________________