DeployLX Software Protection System

SecureLicenseManager..::..DelayedValidationFailed Event

Fired when a DelayedLimit has failed delayed validation.


Public Shared Event DelayedValidationFailed As LicenseEventHandler
public static event LicenseEventHandler DelayedValidationFailed


When a DelayedLimit is validated and has the DelayValidation property set to true, validation will occur asynchronously on a dedicated thread. When validation fails the notification is sent to this event to allow the protected object to respond appropriately. See the DelayValidate(SecureLicenseContext) method for details on asynchronous validation.

Caution Care must be used when subscribing to this event as it may arrive on an a different thread than the original call to Validate(Object, Type, LicenseValidationRequestInfo).


This code demonstrates how to Validate a license that contains a DelayedLimit.
Visual Basic
Imports DeployLX.Licensing.v5


Public Sub DelayedLimitEvents()
    AddHandler SecureLicenseManager.DelayedValidationComplete, AddressOf SecureLicenseManager_DelayedValidationComplete
    AddHandler SecureLicenseManager.DelayedValidationFailed, AddressOf SecureLicenseManager_DelayedValidationFailed

    SecureLicenseManager.Validate(Me, Nothing, Nothing)
End Sub

Private Sub SecureLicenseManager_DelayedValidationFailed(ByVal sender As Object, ByVal e As LicenseEventArgs)
    MessageBox.Show("There are too many users attempting to use the same serial number.")
End Sub

Private Sub SecureLicenseManager_DelayedValidationComplete(ByVal sender As Object, ByVal e As LicenseEventArgs)
    ' Enable features that may have required remote validation
End Sub
using DeployLX.Licensing.v5;


public void DelayedLimitEvents()
    SecureLicenseManager.DelayedValidationComplete += new LicenseEventHandler( SecureLicenseManager_DelayedValidationComplete );
    SecureLicenseManager.DelayedValidationFailed += new LicenseEventHandler( SecureLicenseManager_DelayedValidationFailed );

    SecureLicenseManager.Validate( this, null, null );

void SecureLicenseManager_DelayedValidationFailed( object sender, LicenseEventArgs e )
    MessageBox.Show( "There are too many users attempting to use the same serial number." );

void SecureLicenseManager_DelayedValidationComplete( object sender, LicenseEventArgs e )
    // Enable features that may have required remote validation

Assembly:  DeployLX.Licensing.v5 (in DeployLX.Licensing.v5.dll)

See Also