Sum of the ASCII values of the characters modulo 1024. ALL characters are counted, also non-printing characters like spaces and returns.
Encr_Checksum ( switches ; text )
|switches||reserved for future use, leave empty or set to "-Unused"|
|text||the text to calculate the checksum of|
Data type returned
Troi Encryptor Plug-in 1.2
FileMaker Pro 15 to 19
A checksum might be the same for 2 different texts. The chance on this is normally quite low (one in 1024).
See also the Encr_MakeDigest function for a more robust check if text is the same.
Compatibility with Troi Coding Plug-in:
Text is converted to the FileMaker Pro 6 character set. For other characters the UNICODE value sum modulo 1024 is used. This ensures that fields with data from older FileMaker 6 databases will have the same checksum.
Set Field [ result ; Encr_Checksum ( "-Unused" ; "Hello world." ) ]
will give a result of 106.
You can use this function to see if the contents of a field has changed. You store the checksum and then later compare it to the current checksum.