GetLicenseStatus Class |
Implementation for calling server-side scripts which were originally designed to work with the Automation Client's SK_GetLicenseStatus and SK_GetLicenseStatusEx functions.
Namespace: com.softwarekey.Client.Compatibility.ProtectionPLUS4
The GetLicenseStatus type exposes the following members.
Name | Description | |
---|---|---|
![]() | GetLicenseStatus | Creates a new GetLicenseStatus object. |
Name | Description | |
---|---|---|
![]() | AutomationClientErrorCode | Gets or sets the Automation Client error code. (Inherited from AutomationClientWebFormCall.) |
![]() | ContentEncoding | Gets or sets the encoding used for the request and response (UTF-8 is the default). (Inherited from WebFormCall.) |
![]() | ContentType | Gets or sets the content type ("application/x-www-form-urlencoded" is the default). (Inherited from WebFormCall.) |
![]() | LastException | Gets or sets the last Exception that occurred when calling the web form. (Inherited from WebFormCall.) |
![]() | LicenseID | Gets or sets the License ID (required). |
![]() | LicenseUpdate | Gets the License Update data. |
![]() | Password | Gets or sets password (required). |
![]() | ProductID | Gets or sets the Product ID. When specified, the License ID must be for the Product ID specified. |
![]() | Proxy | Gets or sets the proxy server settings. Leave as null/Nothing to use the system's default proxy settings. (Inherited from WebFormCall.) |
![]() | ProxyAuthenticationRequired | Gets or sets whether the proxy server requires authentication. (Inherited from WebFormCall.) |
![]() | ReplacedBy | Gets the License ID which replaced the License ID which was validated by this object. |
![]() | RequireSsl | Gets or sets whether or not SSL is required. (Inherited from WebFormCall.) |
![]() | Response | Gets or sets the response returned from the server. (Inherited from WebFormCall.) |
![]() | Status | Gets the status of the License ID. |
![]() | StatusCode | Gets or sets the status code of the response returned from the server. (Inherited from WebFormCall.) |
![]() | Timeout | Gets or sets the timeout (in milliseconds). The default is 30000 milliseconds (or 30 seconds). (Inherited from WebFormCall.) |
Name | Description | |
---|---|---|
![]() | CallWebForm | Calls the Automation Client web page. (Overrides AutomationClientWebFormCallCallWebForm.) |
![]() | Equals | (Inherited from Object.) |
![]() | Finalize | Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | (Inherited from Object.) |
![]() | TryParseValueFromResponse(String, Int32) | Tries to parse a 32 bit integer value from the Response. (Inherited from AutomationClientWebFormCall.) |
![]() | TryParseValueFromResponse(String, String) | Tries to parse a string value from the Response. (Inherited from AutomationClientWebFormCall.) |
In general, if you are using SOLO Server, you should be using License.CheckInstallationStatus or the WebServiceCall implementation for status checks. The same information can also be retrieved from SOLO Server using InfoCheck.
![]() |
---|
Before calling the CallWebForm method, the following properties must be set: |
Optional fields that may be populated before calling CallWebForm method include:
public bool RetrieveLicenseStatus(int licenseID, string password, int productID, out string status, out int replacedBy, out string licenseUpdate) { //TODO: The URL used below is for SOLO Server Shared URL. You will need to update this URL if you are using Instant SOLO Server Dedicated URL, or SOLO Server. GetLicenseStatus statusCall = new GetLicenseStatus("https://secure.softwarekey.com/solo/customers/getlicensestatus.asp"); statusCall.LicenseID = licenseID; statusCall.Password = password; statusCall.ProductID = productID; //TODO: Initialize the Proxy property here as appropriate if you need to support proxy server authentication. bool successful = statusCall.CallWebForm(); if (successful) { status = statusCall.Status; replacedBy = statusCall.ReplacedBy; licenseUpdate = statusCall.LicenseUpdate; } else { status = ""; replacedBy = 0; licenseUpdate = ""; //TODO: Evaluate the AutomationClientErrorCode, LastException, and ProxyAuthenticationRequired properties for possible reasons why the call failed. } return successful; }