WWW.NNC.IR
Macro Reference
560
Vision System FH/FZ5 Series
User’s Manual (Z340)
Hex$
Converts the value in the expression to the hexadecimal value in character string format.
Format
Hex$(<expression>)
Parameter
Return value
Returns the character string type hexadecimal value.
If the value in the expression is negative, the two's complement hexadecimal value is returned.
(&H) to express a hexadecimal number is not added to the return value.
Description
Converts the value specified in the <expression> parameter to the hexadecimal value in character string
format.
To specify a double precision real number type expression in the <expression> parameter, convert the
expression to the integer type with Fix or Int in advance.
If an incorrect data type is specified for a parameter, a "Type mismatch" error will occur.
If a value outside the range -2147483648 to 2147483647 is specified as an integer parameter, an "Overflow"
error will occur.
If a value is assigned to the return value variable or the variable is not used in an expression, a "Syntax error"
error will occur.
If the format is written incorrectly, such as writing the macro function name incorrectly, omitting a comma, or
omitting a half-width space, a "Syntax error" error will occur.
Usage Cautions
• None.
Parameter
name
Data type Description
<expression> Integer type Expression to be converted to a character string