cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

Create pdf

krishnakomal123
14-Alexandrite

Create pdf

When I put runtime mashup link in create pdf() service I am getting empty pdf as output.Please check the code below.

 


var params = {
FileRepository: 'FileRepo_Krishnakomal' /* THINGNAME */,
Rotated90Deg: false /* BOOLEAN */,
AppKey: "31ffa8ab-e5d4-416e-960c-2bc40f0c36ba" /* STRING */,
ServerAddress: "http://amrvwp000002634.amer.pfizer.com:8080/Thingworx/Runtime/index.html#mashup=ALLAhusBottomRows_IMU&forceClose=true&__fromNextGen=928e024c-e016-4122-8b8d-d80512da1f40" /* STRING */,
OutputFileName: "MashupReport.PDF" /* STRING */,
Resolution: "1680*1050" /* STRING */
};

// result: STRING
var result = Resources["PDFExport"].CreatePDF(params);

 

 

But if use server address as "https://www.w3schools.com/" ,I am able to get desired data in output pdf file.Could you please let me know where I was wrong.

 

 

4 REPLIES 4

Hello krishnakomal123,

 

Can you please share the name or details of the Extension you are using to get the PDFExport Resource in ThingWorx? I would assume this is the PDF Extension which is no longer available nor supported on the newest versions of ThingWorx.

 

If you have a copy of this Extension which you can provide I can do some best effort testing to see if I can get the desired functionality (CreatePDF of a Mashup). Please send me a Direct Message with the Extension as opposed to posting it here in a reply.

Hi @krishnakomal123.

 

Have you found a solution to your problem?  If so, please feel free to post it here and mark it as the Accepted Solution for the benefit of others on the community.

 

We appreciated your participation!

 

Regards.

 

--Sharon

@krishnakomal123 It is extremely risky from a security perspective to post security credentials (appKey and URL) for a system that you are using, even behind a VPN. I am sure there are automated tools used out there that create snapshots of internet posts like yours, hunting for potential backdoors in customer systems.

Please make sure to disable the appKey you shared as soon as possible.

 

Regarding your issue, this extension is supported by community. If you have issues with it, and nobody answers in this forum, I suggest debugging its source code, available here.

 

Please treat this as a workaround and if you would like to have this feature supported by the ThingWorx platform

post this request in the ThingWorx Ideas forum, available here: https://community.ptc.com/t5/ThingWorx-Ideas/idb-p/thingworxideas

 

Disclaimer: the PDF Extension was never supported by PTC, even when it was in the Marketplace, since it was a Labs Extension.

 

Thank you very much.I have disabled the Appkey.

Top Tags