I have recently come across numeric literals such as 10! and 50# in Visual Basic programs. Could anyone tell me what these punctuation marks mean?
Using these characters specifies the data type of a numeric literal.
I thought this would be covered in the VB6 manual online but I can't find it.
However I just proved it with the TypeName function in the VB6 IDE Immediate Window:
? typename(10!)
Single
?typename(10#)
Double
?typename(10%)
Integer
?typename(10&)
Long
?typename(10@)
Currency
PS Be aware that a VB6 Integer is 2 bytes, -32,768 to 32,767.