|
|
|
|
|
KeyCalcActivationKey (Function) In french: CléCalculeCléActivation Calculates the activation key of application from the initial key. The initial key was generated by KeyGenerateInitialKey. This activation key is unique. Remark: As a general rule, this function is used on the application supplier's workstation: the customer provides the initial key, and the supplier calculates and sends the corresponding activation key..
Secret is string = "]$x+9*EBM%u]yK|R@=y"
CléInitiale is string
CléInitiale = KeyGenerateInitialKey(IDClient)
Info("Votre clé de licence est : " + CléInitiale)
CléActivation is string
Identifiant is string
CléActivation = KeyCalcActivationKey(CléInitiale, Secret)
Identifiant = KeyGetIdentifier(CléInitiale)
Info("Clé d'activation générée pour le client " + Identifiant + " : " + CléActivation)
gbActivationOK = KeyCompareKey(CléInitiale, CléActivation, Secret)
IF gbActivationOK = False THEN
Error("Mauvaise clé d'activation")
EndProgram()
END
Syntax
<Result> = KeyCalcActivationKey(<Initial key> [, <Secret>])
<Result>: Character string Unique activation key corresponding to the initial key. <Initial key>: Character string Initial key supplied by the client of the application. This key was generated by KeyGenerateInitialKey. <Secret>: Character string or Secret string Encryption key used to generate the activation key. We advise you to fill this parameter so that only the application provider can generate a valid key for the application. The same value must be passed to KeyCompareKey.
New in version 2025Secret strings: If you use the secret string vault, the type of secret string used for this parameter must be "ANSI or Unicode string". To learn more about secret strings and how to use the vault, see Secret string vault.
Related Examples:
|
Unit examples (WINDEV): The Key functions
[ + ] Using the functions for calculating the activation keys of WLanguage.
|
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|