Encr_Version (function reference)

By February 1, 2019 February 12th, 2019 Online Help, Troi Encryptor Plug-in
Troi Encryptor Plug-in for FileMaker Pro

Encr_Version

Use this function to see which version of the plug-in is loaded.
Note: This function is also used to register the plug-in.

SyntaxFunction badge

Encr_Version ( switches )

Parameters

switchesdetermines the behavior of the function

Switches

switches can be one of this:

-GetVersionStringthe version string is returned (default)
-GetVersionNumberreturns the version number of the plug-in
-GetPluginInstallPathreturns the path where the plug-in is installed
-ShowFlashDialogshows the Flash Dialog of the plug-in (returns 0)
-GetRegistrationStateget the registration state of the plug-in: 0 = not registered ; 1 = registered
-UnregisterPluginsets the registration state of the plug-in to unregistered

If you leave the parameter empty the version string is returned.

Returned Result

Data type returned

Text

Result

The function returns ? if this plug-in is not loaded. If the plug-in is loaded the result depends on the input parameter. It is either a:

VersionString:
If you asked for the version string it will return for example “Troi Encryptor Plug-in 5.0”

VersionNumber:
If you asked for the version number it returns the version number of the plug-in x 1000. For example version 3.5 will return number 3500.

ShowFlashDialogResult:
This will show the flash dialog and then return the error code 0.

Originated in

Troi Encryptor Plug-in 1.2

Compatibility

FileMaker Pro 14 to 17

Considerations

Important: always use this function to determine if the plug-in is loaded. If the plug-in is not loaded use of external functions may result in data loss, as FileMaker will return an empty field to any external function that is not loaded.

Example

We assume that a calculation number field cVersion is defined like this:

cVersion = Encr_Version

This will evaluate to “Troi Encryptor Plug-in <version number>”. This currently returns “Troi Encryptor Plug-in 5.0”.

Example 2

Encr_Version ( "-GetVersionNumber" )

will return 2600 for version 2.6

Encr_Version ( "-GetVersionNumber" )

will return 2510 for version 2.5.1

Encr_Version ( "-GetVersionNumber" )

will return 5000 for version 5.0.

So for example to use a feature introduced with version 4.0 test if the result is equal or greater than 4000.

Related functionFunction badge

Encr_VersionAutoUpdate

Related topics

Troi Encryptor Plug-in online help (overview)


Online Help Page for Troi Encryptor Plug-in for 14 to 17 –> Encr_Version (encrp9001) 2019-0212 17:28:31