@CONVERTNot in LE
Print Topic  Return to Overview  Previous Topic  Next Topic 

@CONVERT[input, output, value] :  Returns a numeric string value converted from one number base (input) to another (output). Valid bases range from 2 to 36. The value can be between 0 and 2**64-1. No error is returned if value is outside that range.

 

Examples:

    

echo binary 1010101 is decimal %@convert[2,10,1010101]

echo decimal 20 is hex %@convert[10,16,20]

echo hexadecimal FF is octal %@convert[16,8,FF]

echo this year is %@convert[10,2,%_year] in binary

 

See also: @COMMA, @FORMAT, @FORMATN.

 

Topic "f_convert.htm" last edited 5/7/2008. ©2008  JP Software, Inc.
Keywords: @CONVERT