It has been years since I had this problem. Somebody gave me the fix which worked but I decided not to use encryption.
...but I think the decryption problem starts when the string to encrypt exceedes a certian length and the number of characters was odd (or maybe it was even).
I do not remember if it was the "set aspect datakey" command that fixed it.
Comments and code where I was encrypting/decrypting:
===================================================
;...does not work for a string containing three pairs
;of userIDs and Passwords.
;Will "set aspect datakey" fix it?"
;strlen PWcrypt Len
;usermsg "length: %d" len
;encrypt PWcrypt Len
Here is the command description:
===============================
aspect datakey integer
Specifies the integer key used in the encrypt and decrypt commands. fetch returns the value of the current integer key.
For more information on the use of the datakey in encryption, see the encrypt command and the decrypt command.
The datakey value must be equal to the value used to encrypt the string to properly decrypt the string. It can be set with the set aspect datakey command."
This is from the help file:
==========================
"Use caution if writing the encrypted data to a text file. Since the data may contain control characters or even nulls, it is not suitable for a Windows .ini file."