How do I Use hexadecimal numbers in my macro???
Moderators: Dorian (MJT support), JRL
-
- Newbie
- Posts: 1
- Joined: Thu Feb 27, 2003 11:48 pm
How do I Use hexadecimal numbers in my macro???
If anyone can help me use hexadecimal numbering in my macro I would greatly appreciate it. Thanks!!!
Hi,
Use VBScript's Hex and CInt functions. Here's an example:
VBSTART
VBEND
Let>DecVal=450
VBEval>Hex(%DecVal%),HexVal
MessageModal>HexVal
VBEval>CInt("&H" & "%HexVal%"),BackToDec
MessageModal>BackToDec
Let>MyHexVal=&H7fff
VBEval>CInt("%MyHexVal%"),MyDecVal
Use hex values by prepending &H to them.
Use VBScript's Hex and CInt functions. Here's an example:
VBSTART
VBEND
Let>DecVal=450
VBEval>Hex(%DecVal%),HexVal
MessageModal>HexVal
VBEval>CInt("&H" & "%HexVal%"),BackToDec
MessageModal>BackToDec
Let>MyHexVal=&H7fff
VBEval>CInt("%MyHexVal%"),MyDecVal
Use hex values by prepending &H to them.
MJT Net Support
[email protected]
[email protected]