Returns a FixStr (String) value representing the binary value of a number.
Bin[$]([number]) |
The optional number argument is any valid numeric expression or string expression in the range from -2147483648 to 2147483647. If this argument is omitted, is a non-initialized variable, or Null, the function returns 0.
You can represent binary numbers directly by preceding numbers in the proper range with &B. For example, &B10 represents decimal 2 in binary notation.
The Bin$ returns String values. The Bin form returns FixStr values.
Dim MyBin MyBin = Bin(5) ' Returns 101. MyBin = Bin(10) ' Returns 1010. MyBin = Bin(459) ' Returns 111001011. |
See Also |
Oct Function,Hex Function,Type Conversion Functions |