Search found 56 matches
- Tue Apr 11, 2023 4:38 pm
- Forum: Node.js scripting
- Topic: Job.Createdatabase
- Replies: 2
- Views: 7666
Re: Job.Createdatabase
Yes thanks, I was using version 3
- Tue Apr 11, 2023 3:34 pm
- Forum: Node.js scripting
- Topic: Job.Createdatabase
- Replies: 2
- Views: 7666
Job.Createdatabase
I am trying to add a json database that I have used a script to create. I can add the database without issue but I am having trouble sending back via webhook once the database is added. this is the final lines of the code let jsondata = JSON.stringify(iqobj); let fileid = makeid(5); let jsonpath = &...
- Mon Jan 17, 2022 10:54 pm
- Forum: Node.js scripting
- Topic: Stats.NumberOfPages
- Replies: 8
- Views: 12710
Re: Stats.NumberOfPages
Thanks Laurentd,
Really appreciate the replies.
I received an error '@types/switch-scripting@1.1.0' is not in the npm registry.
I just had to change npm i @types/switch-scripting@1.1.0
to
npm i @types/switch-scripting and it updated fine.
Really appreciate the replies.
I received an error '@types/switch-scripting@1.1.0' is not in the npm registry.
I just had to change npm i @types/switch-scripting@1.1.0
to
npm i @types/switch-scripting and it updated fine.
- Sun Jan 16, 2022 10:10 pm
- Forum: Node.js scripting
- Topic: Stats.NumberOfPages
- Replies: 8
- Views: 12710
Re: Stats.NumberOfPages
Thanks Laurentd,
But from what can figure out my script is using verion 1.0.1 of types-switch-scripting, To update to fall 2021 I think I should be using version 21.1.0. What is the best way to update this without writing the script again?
But from what can figure out my script is using verion 1.0.1 of types-switch-scripting, To update to fall 2021 I think I should be using version 21.1.0. What is the best way to update this without writing the script again?
- Fri Jan 14, 2022 4:07 am
- Forum: Node.js scripting
- Topic: Stats.NumberOfPages
- Replies: 8
- Views: 12710
Re: Stats.NumberOfPages
Looking to get the Width and Height of the PDF Document. I have upgraded to Switch Fall 2021 my node script has be written previous to PdfDocument being added to Spring 2021.
What do I need to do to update my script as it is not reconising PdfDocument as a class?
My nodejs version is 14.15.0
What do I need to do to update my script as it is not reconising PdfDocument as a class?
My nodejs version is 14.15.0
- Wed Nov 17, 2021 11:26 pm
- Forum: Applications
- Topic: HP SmartStream VDP
- Replies: 15
- Views: 325287
Re: HP SmartStream VDP
Hey tomgoertz, It was a while ago that I had the issue and I have not used the Smartstream VDP plugin for a while but I found upgrading to Indesign 16.0 fixed my issue. I would suggest to make sure that you don't have any other versions of indesign installed on the server and that you have the lates...
- Mon May 10, 2021 1:40 am
- Forum: Node.js scripting
- Topic: API issues
- Replies: 4
- Views: 7371
Re: API issues
Thanks Freddy, that really helps. I have metadata but it is read only so I didn't bother to specify and the sample I am showing the field names are incorrect so that id why I would be getting the error message. I don't need the metadata it is only there to help debug so will turn off for now. Thanks...
- Wed May 05, 2021 12:20 am
- Forum: Node.js scripting
- Topic: API issues
- Replies: 4
- Views: 7371
Re: API issues
Hi Freddy, I used the job id as returned in the List Jobs call. I also get the connection number from the List Jobs call. The weird thing is that it was working in the 2019 version. I stopped using for a while as I rebuilt some flows during which I upgraded from 2019 to 2020. Now I cannot get the ap...
- Tue May 04, 2021 10:23 am
- Forum: Node.js scripting
- Topic: API issues
- Replies: 4
- Views: 7371
API issues
Hi There, I am currently using the switch api to push through jobs but unfortunalty they are not moving to the next connection. I am using the Job - Route method PUT http://127.0.0.1:51088/api/v1/job/:id?action=route and getting a Success 200 response as below "status": true, "data&qu...
- Mon May 03, 2021 2:23 am
- Forum: Flows
- Topic: Sorting and duplicating pages in PDF
- Replies: 4
- Views: 7722
Re: Sorting and duplicating pages in PDF
Thanks for the reply's sorry I have taken so long to respond. Both idea's are great but I think the major stumbling block is figuring out if the back page is the first or last page in the PDF. I have Callas and Pitstop Server depending on what I need to do. Was thinking maybe using a Text reader and...
- Thu Apr 08, 2021 6:00 am
- Forum: Node.js scripting
- Topic: Help with CSV Split
- Replies: 5
- Views: 8407
Re: Help with CSV Split
Thanks for your help. Below is my final code to split a CSV file and group by the id field. const fs = require('fs-extra'); const fastCsv = require('fast-csv'); const { pipeline } = require('stream') async function jobArrived(s, flowElement, job) { const options = {headers: true, delimiters: ','}; /...
- Wed Apr 07, 2021 12:18 am
- Forum: Node.js scripting
- Topic: Help with CSV Split
- Replies: 5
- Views: 8407
Re: Help with CSV Split
Thanks Freddy, yes I was getting output. At this stage I wasn't too concerned about passing the files back into the flow I just needed the separated CSV files which I had writing to a temp location. The main problem was that the promise was completing before fastcsv would finish writing the new file...
- Wed Apr 07, 2021 12:18 am
- Forum: Node.js scripting
- Topic: Help with CSV Split
- Replies: 5
- Views: 8407
Re: Help with CSV Split
Thanks Freddy, yes I was getting output. At this stage I wasn't too concerned about passing the files back into the flow I just needed the separated CSV files which I had writing to a temp location. The main problem was that the promise was completing before fastcsv would finish writing the new file...
- Mon Apr 05, 2021 1:45 pm
- Forum: Node.js scripting
- Topic: Help with CSV Split
- Replies: 5
- Views: 8407
Help with CSV Split
I have a large CSV file which I want the split into kinds. The file has id's (packNrs) I would like to split using these values. At this stage I have found code that allows me to split on these values but my issue is witting the new CSV files basically I am only get one row written before the next f...
- Sun Jan 17, 2021 10:49 pm
- Forum: Node.js scripting
- Topic: api call from flow
- Replies: 6
- Views: 8126
Re: api call from flow
This is what the above code looks with these changes. const querystring = require('querystring'); const http = require("http"); const XPath = require("xpath"); const fs = require("fs-extra"); const DomPaser = require("xmldom").DOMParser; async function jobArri...