Crypto.Base64DecodeFromString

Crypto.Base64DecodeFromString ( 

string Text,

string Filename )

Example 1

-- base64-encodes a small binary file and store the result in encoded_string
encoded_string = Crypto.Base64EncodeToString("C:\\myfile.exe");

-- Check to see if an error occurred using the Crypto.Base64EncodeToString action.
error = Application.GetLastError();
if (error ~=0) then
    result = Dialog.Message("Error", _tblErrorMessages[error], MB_OK, MB_ICONEXCLAMATION, MB_DEFBUTTON1);
end

-- Display the contents of the string, just to show you what it looks like.
Dialog.Message("This is what the encoded string looks like:", encoded_string);

-- Decode the base64-encoded string and store the result as a binary file.
Crypto.Base64DecodeFromString(encoded_string, _TempFolder.."\\myfile_decoded_string.txt");

-- Check to see if an error occurred using the Crypto.Base64DecodeFromString action.
error = Application.GetLastError();
if (error ~=0) then
    result = Dialog.Message("Error", _tblErrorMessages[error], MB_OK, MB_ICONEXCLAMATION, MB_DEFBUTTON1);
end

Base64 encodes a binary file and stores the result in a string. The string is then decoded and shown in a dialog message.

See also:  Related Actions