Click or drag to resize
PLUS4MethodsValidateTriggerCode Method
Determines whether or not a trigger code is valid. Note this does not process the trigger code or modify the license file in any way.

Namespace: com.softwarekey.Client.Compatibility.ProtectionPLUS4
Assembly: PLUSManaged (in PLUSManaged.dll) Version: 5.17.4.0
Syntax
public static bool ValidateTriggerCode(
	int activationCode1,
	int activationCode2,
	int userCode1,
	int userCode2,
	int tcSeed,
	int dataSeed,
	out int code,
	out int tcData
)

Parameters

activationCode1
Type: SystemInt32
Activation Code 1 (RegKey 1).
activationCode2
Type: SystemInt32
Activation Code 2 (RegKey 2). Pass zero to omit.
userCode1
Type: SystemInt32
User Code 1 (Session Code/Code Entry Number).
userCode2
Type: SystemInt32
User Code 2 (Computer ID).
tcSeed
Type: SystemInt32
Trigger Code Seed.
dataSeed
Type: SystemInt32
Event Data Seed (RegKey2 Seed, which must be a value between 1 and 255).
code
Type: SystemInt32
Trigger Code Number, which will receive a value between 1 and 50 when successful.
tcData
Type: SystemInt32
Trigger Code Event Data, which will receive a value between 0 and 16383 when successful.

Return Value

Type: Boolean
If the trigger code is valid, this method returns true and specifies the trigger code and event data in the code and tcData arguments, respectively.
Remarks
Note Note

If the return value is false, then the Trigger Code is considered invalid. This can be caused for several reasons, including, but not limited to:

  • The user mistyped one or more of the user code and/or activation code values.
  • The Trigger Code Seed used in the application does not match the seed used when generating the trigger code. Check the Product Option configuration in SOLO Server or the Product Definition settings in LFEdit to verify if this is the issue.
  • The session code (User Code 1) is now different from the one used when generating the Trigger Code.
  • The dataSeed (also known as the RegKey2 seed) is not an acceptable value, between 1 and 255.
  • The dataSeed (also known as the RegKey2 seed) is not the same value used when encrypting the tcData value (or when generating activationCode2).
  • The tcData value encrypted (or the value used when generating activationCode2) was too large (or greater than 16383).
See Also