11-09-2007 10:52 AM
11-09-2007 12:46 PM
Hey dome,
Assume Locals.HexString = "0xFFFF".
Assume that Locals.BytePos = 2
Assume that Locals.Length = 4
Assume Locals.Number is where we want to store the result.
This:
Locals.Number = LocalizeExpression("0x" + Mid(Locals.HexString, 2 + Locals.BytePos, Locals.Length))
Returns:
Locals.Number = 255
If you want to force Locals.Number to show up as a Hex value then you need to change the properties of it:
RightClick>>Numeric Format... Change Type: to Hexadecimal.
Hope that helps,
11-12-2007 03:30 AM
11-12-2007 03:53 AM