The decrypt( function decrypts data.


This function has two parameters:

data – the data to be decrypted. This parameter must contain binary data (see Binary Data) that was originally encrypted with the encrypt( function.

password – the password to be used to decrypt the data. This must be the same password used to encrypt the data.


This function decrypts binary data (or text) that has been previously encrypted with the encrypt( function.

Before decrypting something, you first have to encrypt it. This example encrypts the information in the Letter field (or variable) into a file named Letter.secret, using the password My Secret. (Of course you usually would not want to use a fixed password like this.)

filesave "Letter.secret",encrypt(Letter,"My Secret")

Later, when you want to decode the secret letter, you would use code like this:

Letter = decrypt(fileload("Letter.secret"),"My Secret")

If the password used for decrypting doesn’t match the password used for encrypting, an error occurs.

Note: This function encrypts data using AES-256 encryption. See Advanced Encryption Standard for more information.

See Also


10.0NewNew in this version.