3

As described in the title, I am confused by such initialization as "&h3&". What does this mean? Thank you very much.

bholms
  • 39
  • 6
  • Without the `&` at the right side, `&h3` is a hex number (see [hex value in Visual Basic](http://stackoverflow.com/questions/428643/hex-value-in-visual-basic) - the syntax is the same in this case). – Ken White Jun 06 '12 at 16:47

1 Answers1

4

This declares a long variable with the value 3. Here's a quick break down of the syntax

  • &h: In VB this is the prefix which indicates a hexadecimal number. It's the equivalent of 0x in C / C++ / C#
  • 3: The number 3 which is still just 3 when evaluated as a hexadecimal number
  • &: Specifies it should be a long vs normal integral value
JaredPar
  • 733,204
  • 149
  • 1,241
  • 1,454