Question
If there are several activated licenses for FineReader Engine how to automatically switch between them if there are no pages left on the current license?
Answer
To do this, please use GetAvailableLicenses Method of the Engine Object and VolumeRemaining Property of the License Object. For example:
//C#
bool check = true;
var licenses = Engine.GetAvailableLicenses(projectId);
foreach (var lic in licenses)
{
if (lic.VolumeRemaining[FREngine.LicenseCounterTypeEnum.LCT_Pages] > 0)
{
Engine.SetCurrentLicense(lic);
check = false;
break;
}
}
if (check)
{
Engine.SetCurrentLicense(licenses.Item(0));
}
Comments
0 comments
Please sign in to leave a comment.