Check if the Product Code is available and then the Extension Code for that product.
[Visual Basic .NET] Public Function IsExtensionCodeAvailable ( _ ByVal ProductCode As esriLicenseProductCode, _ ByVal extensionCode As esriLicenseExtensionCode _ ) As esriLicenseStatus
[C#] public esriLicenseStatus IsExtensionCodeAvailable ( esriLicenseProductCode ProductCode, esriLicenseExtensionCode extensionCode );
[C++]
HRESULT IsExtensionCodeAvailable(
esriLicenseProductCode ProductCode,
esriLicenseExtensionCode extensionCode,
esriLicenseStatus* licenseStatus
);
[C++]Parameters
ProductCode [in]ProductCode is a parameter of type esriLicenseProductCode
extensionCode [in]extensionCode is a parameter of type esriLicenseExtensionCode
licenseStatus [out, retval]licenseStatus is a parameter of type esriLicenseStatus
Product Availability
Description
The IsExtensionCodeAvailable method returns whether the specified extension license is available with the specified product license that will be used to Initialize the application (not every extension license is available with every product license). The method firstly checks the availability of the product license and secondly checks the availability of the extension license with the product license.
When an application is initialized with a particular product license, a connection is made to a license server. All subsequent calls to the CheckOutExtension and CheckInExtension methods are made to the same license server. As such, you cannot use a combination of licenses from difference license servers or Engine Single Use.
- If an application is initialized with a Desktop Concurrent license, the application will subsequently only be able to access that Desktop Concurrent license server and its extension licenses.
- If an application is initialized with a Desktop Single Use license, the application will subsequently only be able to access that single use license server and its extension licenses.
- If an application is initialized with the Engine Single Use license on your machine, the application will subsequently only be able to access the Engine Single Use extension licenses.
If the licenses you require are available using Engine Single Use then we recommend you use it in preference to the Desktop Concurrent and Desktop Single Use licenses. This means you will not limit the Desktop Concurrent licenses available to any other users.
If an extension required by the application for it to run successfully is not available, the application should inform the user of the issue, and exit the application. If the extension functionality is not necessary for the application to function, and the extension license is unavailable, the application should disable to the user the functionality dependant upon the extension.