Type validation

  • Thread starter Thread starter Samuel Shulman
  • Start date Start date
S

Samuel Shulman

Is there method to verify that a value is integer and not double

Thank you,
Samuel
 
You can take its ceiling or floor, and compare it to the original value. If
they are the same, then it is an integer.
 
Let's see if anyone guesses what is the
ceiling of 10.000000000000001D

:)

-tom

Samuel Shulman ha scritto:
 
:) try

MsgBox(Math.Ceiling(10.000000000000001D))

with both VB2003 and then with VB 2005. You will see at MS
have changed opinion about the result :)

-tom

Samuel Shulman ha scritto:
 
Any explanation?


:) try

MsgBox(Math.Ceiling(10.000000000000001D))

with both VB2003 and then with VB 2005. You will see at MS
have changed opinion about the result :)

-tom

Samuel Shulman ha scritto:
 
Back
Top