Int64Static: Parse |
Converts the string representation of a number to its 64-bit signed integer equivalent.
Public Function Parse( ByRef s As String ) As Int64
The s parameter contains a number of the form:
[ws][sign]digits[ws]
Elements in square brackets ([ and ]) are optional. The following table describes each element.
Element | Description |
---|---|
ws | Optional white space. |
sign | An optional sign. |
digits | A sequence of digits ranging from 0 to 9. |
The s parameter is interpreted using the NumberStyles.Integer style. In addition to decimal digits, only leading and trailing spaces together with a leading sign are allowed. To explicitly define the style elements that can be present in s, use Int64.ParseEx(String, NumberStyles) or the Int64.Parse(String, NumberStyles, IFormatProvider) method.
A string expression beginning with "0x" or "&h" will be parsed as a hex value.
Exception | Condition |
---|---|
FormatException | s is not in the correct format. |
OverflowException | s represents a number less than MinValue or greater than MaxValue. |