Advanced Installer 6.7 has a new licensing and registration feature which allows for time-limited demos/trials and registration of installed software.
Caphyon, the maker of Advanced Installer, provides code samples and documentation on licensing integration for C++ and C# applications. To use this feature, the application must make a call into an Advanced Installer library and handle its return code.
The library is a gatekeeper to the rest of the application, effectively deciding whether or not the application is allowed to run. It determines the software’s trial status and displays a registration dialog, terminates the application, or returns a code, accordingly. The Java implementation of this feature works a little differently.
For those using the Java Launcher, integrating the licensing feature is easy: simply add the Java Product on the Licensing Options tab. But, what about those who don’t use Java Launcher? Or those that wish to enable users to register from within the application?
There is no official documentation which answers these questions, but based on a discussion following a request for help I posted on the Advanced Installer forums, I was able integrate AI’s licensing feature into my Java application without using the Java Launcher.
My solution mirrors the C++ implementation and is remarkably simple. Thanks to Cosmin, a member of the Advanced Installer support team, for sending me in the right direction.
Note: The above uses Java Native Access (JNA) to invoke the Advanced Installer library.