Free Support Forum - aspose.com

Activating license in .Net

I purchased Aspose Word and PDF. I placed the license file in the bin directory of my project along with the word and pdf dlls. I've added the license to the project. I've set the build action to embedded resource. I am still seeing the evalution watermark when I run a report.

Could you let me know any other steps required to activate the license in the .Net project?

Hi

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thanks for your inquiry. You should run the following code to set license.

Aspose.Words.License license = new Aspose.Words.License();

license.SetLicense("Aspose.Words.lic");

Please see the following link to learn how to apply license.

http://www.aspose.com/documentation/file-format-components/aspose.words-for-.net-and-java/applying-a-license.html

Hope this helps.

Best regards.

Do I run this code in every class that implements the Aspose Word or PDF reporting tool?

If so is there a way to configure the license as part of the project rather than in individual classes?

Hi<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

No, you should run this code once per application domain. Please see the following link to learn when to apply license.

http://www.aspose.com/documentation/file-format-components/aspose.words-for-.net-and-java/when-to-apply-a-license.html

Best regards.