When using BASE64 encoding or HEX-ENCODE and HEX-DECODE functions on systems where the CPU endian-ness is not the same, ensure that both sides of the application use the SET-BYTE-ORDER function when building the data so that the byte order of the MEMPTR variables is the same between the platforms:
- HEX and BASE64 encoding does not do any byte-ordering. The code simply goes byte-by-byte starting at the first byte in the RAW value passed so the result will be dependent on the machine's endianness
- SET-BYTE-ORDER puts the values in the RAW value in the byte order required.