We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Set Aspose.Pdf License via dll

Hi, I have multiple applications where I want to use Aspose pdf. It would be difficult that I write the code and include license file in each application. is there a way that I embed license in one application and then include dll of that application in all other application to reflect the license?



Please advise.

Hi Vikram,


Thanks for contacting support.

The license initialization is required when first object of Aspose.Pdf is created. However if your applications are sharing same object, you can initialize the license in one application and use the same object in other applications but its not a recommended approach. You may include license as Embedded Resource.

Its recommended to place the license initialization code n some static method which is executed once at that start of application. There is no need to re-initialize the license in multi-threaded environment when a new thread is created. The license is valid until the main application thread is running.

May be you can place the license initialization code in Main(), Page_Load() or any method which is executed at the start of application.