Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- GetIt Reference Guide - syntax: ch_hextobin(<hexc> [,<@memvarc> [,<position>]]) http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
Syntax: CH_HEXTOBIN(<hexC> [,<@memvarC> [,<position>]])

Converts hex string to binary string

Returns binary string

Example

? CH_HEXTOBIN("454647")
  EFG

var = "ABCD___HIJ"
CH_HEXTOBIN("454647",@var,5)
? var
  ABCDEFGHIJ

Notes

The number of binary bytes returned is the number of hex digits/2.  If an
odd number of hex digits is specified, there will be an implied '0' in
the leftmost position.  All hex digits, including leading zeros '0',
and leading and trailing blanks are significant, thus the hex string
must be scaled to the desire length.

If a memory variable is specified, the resulting binary string will be stored
into the string starting at the specied <position>.  If <position> is
omitted, 1 is assumed.

No check is made for valid hex digits, nor is any error generated if
you attempt to store beyond the end of <memvar>.

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson