Hellow
I am looking for an elegant solution to determine if a variant is a whole number in VBA. Unfortunately, if the variant was created from a string, I am stuck. Here's a little test script:
dim v as variant
v = "42"
if v <> round(v) then
msgBox("<>")
end if
Here, the msgBox pops up, probably because the variant was created from a string, although I would have expected v to be = round(v).