Dim strMessage As String strMessage = "0415877D57" If IsNumeric(strMessage) Then MsgBox CDbl(strMessage) Else MsgBox "not numeric" End If
我猜测运行时引擎错误地认为D实际上是E?
我认为这是一个错误,因为VB.NET中完全相同的代码输出不是数字
这是IsNumeric的已知问题吗?
Dim strMessage As String strMessage = "0415877D57" If IsNumeric(strMessage) Then MsgBox CDbl(strMessage) Else MsgBox "not numeric" End If
我猜测运行时引擎错误地认为D实际上是E?
我认为这是一个错误,因为VB.NET中完全相同的代码输出不是数字
这是IsNumeric的已知问题吗?
Note Floating-point values can be expressed as mmmEeee or mmmDeee,in which mmm is the mantissa and eee is the exponent (a power of 10). The highest positive value of a Single data type is 3.402823E+38,or 3.4 times 10 to the 38th power; the highest positive value of a Double data type is 1.79769313486232D+308,or about 1.8 times 10 to the 308th power. Using D to separate the mantissa and exponent in a numeric literal causes the value to be treated as a Double data type. Likewise,using E in the same fashion treats the value as a Single data type.