License Methods
Method | Description |
---|---|
InitLicense |
Initializes license key and activate the SDK. |
GetIdleInstancesCount |
Gets available instances count when charging by concurrent instances count. |
InitLicenseFromServer |
Deprecated |
InitLicenseFromLicenseContent |
Deprecated |
OutputLicenseToString |
Deprecated |
InitDLSConnectionParameters |
Deprecated |
InitLicenseFromDLS |
Deprecated |
InitLTSConnectionParameters |
Deprecated |
InitLicenseFromLTS |
Deprecated |
InitLicense
Initializes license key and activate the SDK.
static EnumErrorCode Dynamsoft.DBR.BarcodeReader.InitLicense (string license, out string errorMsg)
Parameters
[in] licenseKey
<string> : The license key of Barcode Reader.
[out] errorMsg
<string> : The detailed error message.
Return Value
Returns error code (returns DBR_SUCCESS if the function operates successfully).
You can check errorMsg
to get detailed error message.
Code Snippet
string errorMsg;
BarcodeReader.InitLicense("YOUR-LICENSE-KEY", out errorMsg);
BarcodeReader reader = new BarcodeReader();
// add further process
GetIdleInstancesCount
Gets available instances count when charging by concurrent instances count.
static int Dynamsoft.DBR.BarcodeReader.GetIdleInstancesCount()
Return Value
Returns available instances count.
- 0: There is no space for new instance
- -1: The available count needs to be updated from server by calling InitLicense.
- N ( N > 0 ): N more instances can be created.
Code Snippet
//...
int count = BarcodeReader.GetIdleInstancesCount();
if(count > 0)
{
//create instance and process further
}
if(count < 0)
{
//call InitLicense
//create instance and process further
}
if(count = 0)
{
//waiting for available instances
}
InitLicenseFromServer
Deprecated
. It still works in this version but could be removed in the near future.
int Dynamsoft.DBR.BarcodeReader.InitLicenseFromServer(string licenseServer, string licenseKey)
InitLicenseFromLicenseContent
Deprecated
. It still works in this version but could be removed in the near future.
int Dynamsoft.DBR.BarcodeReader.InitLicenseFromLicenseContent(string licenseKey, string strLicenseContent)
OutputLicenseToString
Deprecated
. It still works in this version but could be removed in the near future.
string Dynamsoft.DBR.BarcodeReader.OutputLicenseToString()
InitDLSConnectionParameters
Deprecated
. It still works in this version but could be removed in the near future.
static DMDLSConnectionParameters Dynamsoft.DBR.BarcodeReader.InitDLSConnectionParameters()
InitLicenseFromDLS
Deprecated
. It still works in this version but could be removed in the near future.
static EnumErrorCode Dynamsoft.DBR.BarcodeReader.InitLicenseFromDLS(DMDLSConnectionParameters dlsConnectionParameters, out string errorMsg)
InitLTSConnectionParameters
Deprecated
. It still works in this version but could be removed in the near future.
InitLicenseFromLTS
Deprecated
. It still works in this version but could be removed in the near future.