Dtx Function

Converts a decimal integer to hexadecimal.

Syntax

Dtx (number [ ,size] )

number is the decimal number to be converted. If number is a null value, null is returned.

size is the minimum number of characters in the hexadecimal value. The returned value is padded with leading zeros as required. If size is a null value, a runtime error occurs.

Example

This is an example of the Dtx function used to convert a decimal number to a hexadecimal string representation:

MyNumber = 47
MyHex = Dtx(MyNumber)               ;* returns "2F"
MyHex = Dtx(MyNumber, 4)               ;* returns "002F"