Free Support Forum - aspose.com

How to check whether the license status?

Dear Support,

I am using Aspose.Pdf 8.7.0.0 (Licensed)..
Sometimes we are getting evaluation copy of document,
how to check whether the license status? .. so whenever the license is not loaded then I would apply the following:

lic_pdf = new Aspose.Pdf.License();
lic_pdf.SetLicense("Aspose.Pdf.lic");
lic_pdf.Embedded = true;

Please advise..

many thanks in advance

Regards
Win

Hi Winanjaya,


Thanks for contacting support.

In order to accomplish this requirement, a static read-only property named IsLicensed is added in Document class.

[C#]
// determine if the API is licensed
if (Document.IsLicensed)
{
// print message that license is applied
Console.WriteLine(“Licensed”);
}