""Peter Huang" [MSFT]" wrote:
> Hi
>
> This depends on which number you will use.
> Char.IsDigit Method
> This method determines if a Char is a radix-10 digit.
>
> DecimalDigitNumber
> Supported by the .NET Compact Framework.
> Indicates that the character is a decimal digit; that is, in the range 0
> through 9. Signified by the Unicode designation "Nd" (number, decimal
> digit). The value is 8.
>
> Char.IsNumber
> This method determines if a Char is of any numeric Unicode category
> Valid numbers are members of the following categories in UnicodeCategory:
> DecimalDigitNumber, LetterNumber, or OtherNumber.
>
> LetterNumber
> Supported by the .NET Compact Framework.
> Indicates that the character is a number represented by a letter, instead
> of a decimal digit; for example, the Roman numeral for five, which is 'V'.
> Signified by the Unicode designation "Nl" (number, letter). The value is 9.
>
> OtherNumber
> Supported by the .NET Compact Framework.
> Indicates that the character is a number that is neither a decimal digit
> nor a letter number; for example, the fraction 1/2. Signified by the
> Unicode designation "No" (number, other). The value is 10.
>
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/
> frlrfsystemglobalizationunicodecategoryclasstopic.asp
>
>
> That is to say if you just wants to parse the string consist of 0-9,
> IsDigit is enough, or you need to use the IsNumber.
> IsNumber will consider the 'a' as a radix-16 number.
>
>
>
>
> Best regards,
>
> Peter Huang
> Microsoft Online Partner Support
>
> Get Secure! -
www.microsoft.com/security > This posting is provided "AS IS" with no warranties, and confers no rights.
>