This document is archived and information here might be outdated.  Recommended version.


IAoInitialize.IsProductCodeAvailable Method (ArcObjects .NET 10.4 SDK)
ArcObjects Library Reference (System)  

IAoInitialize.IsProductCodeAvailable Method

Check if the Product Code is available.

[Visual Basic .NET]
Public Function IsProductCodeAvailable ( _
    ByVal ProductCode As esriLicenseProductCode _
) As esriLicenseStatus
[C#]
public esriLicenseStatus IsProductCodeAvailable (
    esriLicenseProductCode ProductCode
);
[C++]
HRESULT IsProductCodeAvailable(
  esriLicenseProductCode ProductCode,
  esriLicenseStatus* licenseStatus
);
[C++]

Parameters ProductCode [in]
ProductCode is a parameter of type esriLicenseProductCode licenseStatus [out, retval]
licenseStatus is a parameter of type esriLicenseStatus

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

The IsProductCodeAvailable method returns whether the specified license is available. If the license is available it can be used to Initialize the application.

If the product you require is not available you may want to check whether a higher product license is available to Initialize the application with. If the license you require is 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 there are no appropriate product licenses available the application should inform the user of the issue, and either allow the user to resolve the issue or exit the application.

See Also

IAoInitialize Interface