Table of Contents
Installing the plugin
CalendarSet is provided as a bundle for both Windows and MacOS: there is just one version for both platforms. To install it, simply copy the file CS.bundle into your Plugins folder.
Plugins folders can be located in one of two locations:
- In the 4D application folder (4D or 4D Server). When plugins are installed in this location, they will be available to every database that is opened with that application.
- Next to the database structure file for your project: in this case, the plugin will only be available to that database. On MacOS, this means that the Plugins folder must be placed within the database package or folder. To open a package, ctrl-click on the package and choose Show Package Contents from the contextual menu.
Using CalendarSet in Demo mode
You can use CalendarSet in Demo mode for 20 minutes, after which time it will cease to work. When this becomes annoying, it’s time to buy a license, which you can do on our website.
Licenses are either linked to the 4D product number, the workstation or the company name as described below.
Like all e-Node professional tools, CalendarSet offers several license types. There are no such things as MacOS vs Windows or Development vs Deployment.
For current pricing, please see the ordering page on our website.
Regular licenses are used for applications that are opened with 4D Standalone or with 4D Server, either in interpreted or compiled mode (doesn’t make a difference regarding plugin licensing). These can be either single user or server databases and they are linked to the 4D or 4D Server license: you need to provide the number returned by the “Copy” or “eMail” buttons from the plugin demonstration mode alert (this number is actually the 4D command GET SERIAL INFORMATION first parameter). This number is a negative long integer such as -1234567.
Merged licenses are used for double-clickable applications built with 4D Volume Desktop (single user) or with 4D Server by means of the 4D Compiler module. They also apply to compiled structures opened with 4D SQL Desktop. These licenses are linked to the machine ID (single user workstation or server): you need to provide the number returned by the “Copy” or “eMail” buttons from the plugin demonstration mode alert (this number is calculated from the single user or server machine UUID). On 4D Server any remote client will return the server number. This number is a positive long integer such as 1234567.
In both cases the demonstration mode dialog will display the proper number according to the current setup (regular or merged) and the “Copy” and “eMail” buttons will use it as well.
A new license will be supplied for free at any time (maximum once a year) if you change your 4D version or get a new 4D registration key for the same version, provided that your previous license match the current public version at exchange time. This rule applies whether you are already using the new version or not: just specify that you also want a key for the older version as well as the current one when you order an upgrade.
These licenses are independent from the 4D versions and product numbers. They will remain functional if you upgrade e.g. from 4D v17 to 4D v18 on the same machine (single user workstation or server).
You’ll only need to update a merged license if your machine or motherboard is replaced (a new license will be supplied for free in this case, provided that your previous license match the current public version at the exchange time), or if you install a paid upgrade of the plugin.
Note: if you are using several concurrent versions of 4D you will need one plugin license for each version.
This license allows development (interpreted mode) or deployment (interpreted or compiled mode, including merged) of applications that are opened with 4D Standalone or 4D SQL Desktop or built with 4D Volume Desktop.
These licenses allow development (interpreted mode) or deployment (interpreted or compiled mode, including merged servers / remotes) on 4D Server with up to 10 users (“small server”), 11 to 20 users (“medium server”) or more (“large server”).
Unlimited Single User
This license allows development (interpreted mode) or deployment (interpreted or compiled mode, including merged) on any number of 4D Standalone (or single user merged applications built with 4D Volume Desktop) that run your 4D application(s).
It is a yearly license, which expires after the date when it is to be renewed. Expiration only affects interpreted mode. Compiled applications using an obsolete license will never expire.
A single license key will unlock all setups on all compatible 4D versions and all versions of the plugin. The license key is linked to the developer/company name.
This license allows deployment (selling new application licenses, updates or subscriptions) while the license is valid. No new deployment may occur after expiry without a specific license (merged or regular). End-users running deployments sold during the license validity period remain authorized without time limit, provided that they are no longer charged for the application using the plug-in (including maintenance or upgrades).
This license allows development (interpreted mode) or deployment (interpreted or compiled mode, including merged) on any number of 4D Servers (any number of users), 4D Standalone or single user/remote merged instances that run your 4D application(s).
It is a yearly license, under the exact same terms as the Unlimited Single User license described above, except that it also covers server deployments.
This license is a global OEM license, covering any combination of the plug-ins published by e-Node, including AreaList Pro, SuperReport Pro, PrintList Pro, CalendarSet and Internet ToolKit in all configurations.
For each product, a single registration key allows development (interpreted mode) or deployment (interpreted or compiled mode, except merged) on all 4D Standalones and 4D Servers (2 users) regardless of 4D product numbers, OS and versions. No merged applications or 4D SQL Desktop mode.
This is a yearly license, expiring on February 1st (same date as 4D Partner licenses). Expiration only affects interpreted mode. Compiled applications using an obsolete license will never expire.
Note: you don’t have to be a 4D Partner subscriber to subscribe to the e-Node Partner license.
Registering your CalendarSet License
Once you have purchased your license, you will receive a registration key. This code must be registered each time the database is started.
There are three ways to register your license:
- using the Demo mode dialog “Register” button,
- though a text file,
- in your 4D code with the CS_Register command.
Both Register button and 4D code registrations can be performed in one single step through the Online instant activation system.
Yearly licenses such as Unlimited single user, OEM and Partner licenses do not require any serial information or online instant activation. The only way to register these licenses is through the CS_Register command.
Quick and easy way – End-user online instant activation
- Make sure that the machine where the plugin will be used is connected to the Internet (single user workstation or in server mode the first remote client that will connect to the server).
- Launch your application. Displaying any layout that uses the plugin will trigger the demonstration mode dialog.
- The plugin will display an alert indicating that it is now registered.
Note: this method does not require your source code to be modified or recompiled.
Quick and easy way – Developer online instant activation
1. Put the following lines of code into your On Startup database method, with the Master key that you received and your email address
C_LONGINT ($result) $result:=CS_Register ("yourMasterKey";0;"email@example.com") // 0 if successful
2. Make sure that the machine where the plugin will be used is connected to the Internet (single user workstation or in server mode the first remote client that will connect to the server).
3. Install your application.
4. Launch your application. Displaying any layout that uses the plugin will silently (no dialog) register it.
5. You will receive an email with the final key that was issued and the IP address of the user site.
If the site has no Internet connection or if you want to use the plugin license system to help protect your own software copy, you can manage the final key registration yourself using one of the following methods.
The Demonstration mode dialog
This is performed from the demonstration mode dialog, displayed upon the first call to CalendarSet (through a command).
To trigger this display and enable your users to register without actually calling a command or setting up an area, pass an empty string to CS_Register and the dialog will show:
C_LONGINT ($result) $result:=CS_Register ("") // display the dialog
Note: calling CS_Register with any key (valid or invalid) will not display the dialog.
Retrieving the serial / machine information
The Demo mode dialog includes all relevant information (serial or machine ID, see Definitions) to obtain your license, as well as a “Copy” button to put this information into your clipboard or a text file, an “eMail” button to email the information to e-Node’s registration system and a “Register” button to enter your license key once received:
Using the “Register” button
Paste or drag and drop your registration key and, if correct, the plug-in will be registered for all future uses on this workstation:
Note: if 4D does not activate the Edit > Paste menu item click Abort and Register again, or try drag and drop. Note: you can directly paste the Master key that was delivered when using the Online instant activation.
Registering Server licenses
Similarly, server licenses can be registered from the demonstration mode dialog without having to modify your code and use CS_Register (which of course you can do with any license type). In this case, the 4D Licenses folder, serial information or machine ID used will only be the 4D Server information, not the client workstation’s.
Server licenses can be registered on any client workstation (remote mode), or on 4D Server itself.
Registering in Remote mode
The server and all workstations can be registered from any single client workstation connected to the server. As in Single user mode, the Demo mode dialog will be displayed on a client workstation when one of the following conditions are met:
- Calling a CalendarSet command other than CS_Register with a non-empty parameter
- Calling CS_Register with an empty string
Use the Copy, eMail and Register buttons just as above and your server will be registered for all workstations.
Note: any other workstations previously connected (before registration occurred) will need to re-connect to the server to be functional.
Registering on 4D Server
To directly register the server and all workstations from the server machine itself, you need to display the Demo mode dialog on the server.
Call CS_Register with an empty string in the On Server Startup base method:
C_LONGINT ($result) $result:=CS_Register ("") // display the dialog
Use the Copy, eMail and Register buttons just as above and your server will be registered for all workstations.
Note: the dialog will automatically be dismissed on the server after one minute in order not to block client connections (the server is only available to client workstations once the On Server Startup method has completed).
Merged licenses notes
Both methods can be either used with regular or merged servers and client workstations.
- Regular licenses are linked to the 4D Server serial information
- Merged licenses are linked to the 4D Server machine ID
Note: merged licenses will keep working if your 4D Server serial information is modified (upgrading or 4D Partner yearly updates), or if any client workstation hardware is changed.
It will only need to be updated if the 4D Server hardware is changed, or if the plugin itself requires a new key (paid upgrades upon major version changes).
You may want to register your merged server without having to turn off the database to modify the code. We have created a utility database to manage this - it’s called Get Serial Info and you can download the appropriate version for your 4D version from the e-Node server.
This is possible using any 4D setup on the server machine (such as a standard developer single user 4D). Keeping your production server alive, open the Get Serial Info database with 4D on the same server machine. Ignore the demonstration mode dialog (if your single user 4D is not registered for the plugin) and wait for the next Alert:
A text file is also saved with the same information.
The last line “Machine ID” is the number that you need to send in order to receive your merged server registration key.
You can also check the machine ID in standalone mode (or on any remote client with the built-client application or in interpreted mode as long as it is running on the same server machine) with AreaList Pro using the following call:
C_LONGINT($machineID) $machineID:= AL_GetAreaLongProperty (0;"mach")
Note: you don’t need an AreaList Pro license to do this.
Using a text file
Alternatively, you can place a plain text file into your 4D Licenses folder.
To open this folder from 4D use the 4D Menu Help > Update licenses, then click the Licenses Folder button:
The text file must be called “CS6.license4Dplugin” and be a plain text type file.
Just paste all your licenses for CalendarSet v6.x, one per line, e.g.:
Any license type can be included into this document, except unlimited single user, OEM and Partner licenses.
Note: the Demo mode dialog Register button actually does this: create the text file and include the license key, or add the license key to the existing document if any. Note: when using the Online instant activation system, the Master key is automatically converted to a Final key according to the current environment and this final key is stored into the license file.
1. Open the On Startup database method
2. Call the CS_Register function with your registration key - for example:
$result:=CS_Register ("YourRegistrationKey") // result = 0 means registration was successful
If you have several licenses for different 4D setups you can call CS_Register multiple times in a row without further testing. See the Example with multiple calls.
When such a file exists in the Licenses folder CalendarSet will check for valid licenses from this document as a first action before anything else (including checking any CS_Register command).
If a valid license is included into the “CS6.license4Dplugin” document any calls to CS_Register will return zero (for “OK”). Therefore you can mix modes and use the text file (or Register button) as well as the command.
Unlimited single user, OEM, temporary and Partner licenses can only be entered through the CS_Register command.
Online instant activation
CalendarSet provides an automated solution to register itself using an Internet connection.
This feature can be helpful whenever you don’t want to bother your end user with plugin registration, or want to save the time to collect the serial / machine ID, or any other reason when you want the process to be entirely and automatically managed from the client site.
It can also be used for your own development tools, removing the need to modify your 4D code to include or update registration licenses.
Note: the site must have an open outgoing HTTP Internet connection available.
The basic principle is that we deliver a non-assigned license key, called “master key”, which you use in your call to CS_Register in your On Startup database method. This key will be used to generate valid keys for the plugin and environment, called “Final keys”.
One single master key can generate as many final keys as you need, in case you order several licenses of the same kind (regular or merged, single user licenses or server licenses of the same size).
A master key looks like a final key, except that the second part is the plugin code name (same as the license file name) instead of the serial / machine ID, e.g. “123456-CS6-xyz”.
Passing a master key as the first parameter to CS_Register when the plugin has not been previously registered by any of the methods above will result in a connection attempt to e-Node’s license server as described below.
If the plugin has not been previously registered (through Online instant activation, text file, register button or CS_Register with a final key), and if CS_Register receives a master key in its first parameter, it will recognize it a such, then:
1. Connect to e-Node’s license server.
2. Ask the server if the master key has not been assigned yet (or if the master key is designed to generate several final keys, if there is any unassigned key up to that number).
3. Send the serial information (regular licenses) or the machine ID (merged licenses) to the license server.
4. If an error is detected (such as master key not matching the current setup) return an error to CS_Register.
5. If the master key is valid, receive its final key from the license server then register itself (writing into the license file).
Note: if a final key has already been issued for this serial / machine ID using this master key, it is simply resent.
In addition, CS_Register second parameter allows optional settings regarding the user interface in the online registration process.
C_LONGINT ($result) $result:=CS_Register ("Master key";0 ?+1 ?+2 ?+3;"firstname.lastname@example.org") // all dialogs
Display a confirmation dialog before step 1
Display an alert at step 4
Display an alert at step 5
The third parameter to CS_Register (optional) is the developer email to whom the information will be sent (if this parameter is used and non empty, of course).
The emailed information includes both the final key issued and the IP address from where it was requested (and to where it was sent for registration).
- When a key is issued:
Subject: CS6 license Body: License 123456-123456789-abcdefgh issued to 126.96.36.199
- When a key is resent:
Subject: CS6 license Body: License 123456-123456789-abcdefgh resent to 188.8.131.52
The default mode (master key being passed as the only parameter) is silent: no confirmation, no alert, no email.