Can't set license in node.js

Stimulsoft Reports.JS discussion
Post Reply
djjoyro
Posts: 39
Joined: Tue Apr 05, 2011 4:50 am
Location: România

Can't set license in node.js

Post by djjoyro »

Hello,

I'm running stimulsoft-reports-js v2024.3.3 and I need to render some reports (and also pdf files) from the server side, from node.js.
By default I see in the console: "You are using a trial version of the Stimulsoft product!" and watermark is present on reports

When I try to add the license with:

Code: Select all

Stimulsoft.Base.StiLicense.key = "6vJhGtLLLz2GNviWmU..." +
    "..." +
    "..." +
    "..." +
    "..." +
    "..." +
    "..." ;
I receive this error in the console:

Code: Select all

TypeError: Cannot read properties of null (reading '0')
    at J.fromNetJsonString (D:\Git\V4\reports-worker\src\node_modules\stimulsoft-reports-js\Scripts\stimulsoft.reports.js:13:145739)
    at $O.loadFromString (D:\Git\V4\reports-worker\src\node_modules\stimulsoft-reports-js\Scripts\stimulsoft.reports.js:16:194621)
    at $O.decryptFromString (D:\Git\V4\reports-worker\src\node_modules\stimulsoft-reports-js\Scripts\stimulsoft.reports.js:16:196124)
    at $O.get2 (D:\Git\V4\reports-worker\src\node_modules\stimulsoft-reports-js\Scripts\stimulsoft.reports.js:16:196371)
    at tR.jWesH (D:\Git\V4\reports-worker\src\node_modules\stimulsoft-reports-js\Scripts\stimulsoft.reports.js:16:196787)
    at set key [as key] (D:\Git\V4\reports-worker\src\node_modules\stimulsoft-reports-js\Scripts\stimulsoft.reports.js:16:196585)
Can you help me to correctly set the license on the server side ?
Thank you.
Max Shamanov
Posts: 990
Joined: Tue Sep 07, 2021 10:11 am

Re: Can't set license in node.js

Post by Max Shamanov »

Hello,

Please see the following links to see how to activate the product:
https://www.stimulsoft.com/en/documenta ... vation.htm
https://www.stimulsoft.com/en/blog/arti ... components

If the issue still persist, please send us your request with a detailed description on support@stimulsoft.com.

Thank you.
djjoyro
Posts: 39
Joined: Tue Apr 05, 2011 4:50 am
Location: România

Re: Can't set license in node.js

Post by djjoyro »

Hello,

Thank you for your answer.
I was adding the license from a different file, not from the entry point of the application.
After moving it to the first lines of the index.ts file, it just worked.

Thank you again.
Max Shamanov
Posts: 990
Joined: Tue Sep 07, 2021 10:11 am

Re: Can't set license in node.js

Post by Max Shamanov »

Hello.

We are always glad to help you.
Let us know if you need our help.

Thank you.
Post Reply