Search found 74 matches
- Thu Apr 22, 2021 7:42 am
- Forum: LEGACY scripting
- Topic: Get E-Mails as .eml?
- Replies: 1
- Views: 38
Get E-Mails as .eml?
Is it possible to write a Script to connect to a pop3 and get new mails and save it as ".eml"?
- Thu Apr 22, 2021 7:34 am
- Forum: Switch
- Topic: Receive E-Mails as ".eml" possible?
- Replies: 1
- Views: 25
Receive E-Mails as ".eml" possible?
Hi there,
as far as I know when using the incoming E-Mail Node we receive a Folder with a txt or when specified the attachments
Is it somehow possible to receive the E-Mail itself as ".eml"?
Thanks in Advance for any hint.
as far as I know when using the incoming E-Mail Node we receive a Folder with a txt or when specified the attachments
Is it somehow possible to receive the E-Mail itself as ".eml"?
Thanks in Advance for any hint.
- Thu Dec 10, 2020 3:15 pm
- Forum: LEGACY scripting
- Topic: Merge two text files
- Replies: 2
- Views: 1401
Merge two text files
Hello, I need to run a OCR on PDF Files. I want to use Tesseract. Tesseract need pictures so I build a Flow to convert PDF to JPEG and read them with OCR. Tesseract spits out txt files. I then want to read in those text Files in my script and use RegEx to sort them by specific identifiers and finall...
- Fri Nov 20, 2020 10:59 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
Re: Select a file from the beginning of a flow
Okay this worked for me now:
Code: Select all
var dataset = job.getDataset( "OpaqueJson" );
var jsonFilePath = dataset.getPath();
var jsonFileObj = File.read( jsonFilePath ,'utf-8');
var orderJson = JSON.parse( jsonFileObj );
- Fri Nov 20, 2020 10:25 am
- Forum: LEGACY scripting
- Topic: DPD SOAP API
- Replies: 10
- Views: 3544
Re: DPD SOAP API
We've been integrating with DPD as well (Portugal), and it will be different, but maybe some of this can be helpful. DPD Portugal still doesn't have a REST API, as far as I know, so we've been using SOAP as well. We ended up using a script (still legacy) to build the XML file, according to the docu...
- Fri Nov 20, 2020 9:41 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
Re: Select a file from the beginning of a flow
So you mean the Flow Element "Export Metadata"? So I cant use job.getVariableAsString( '[Metadata.Rational:Path="Opaque"] ')? In My Flow I get a JSON from a WebHook within the JSON is the name of the PDF-File I want to print via "Flux Server API" and various information for the job. So I need the PD...
- Fri Nov 20, 2020 9:07 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
Re: Select a file from the beginning of a flow
Is there a way to "File.read()" a File thats not in the actual Job-Folder of the Script? How can I refer to such a file? For Example the JSON file is in Folder 11 how can I read it by refering to it like File.read('Ordner 11/filename.json')!?
- Thu Nov 19, 2020 9:09 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
Re: Select a file from the beginning of a flow
You renamed the payload file and also changed the extension. The filename before the extension must be alike but different extensions. The filetype you want to embed as an opaque datatype i specified in the properties. You you need two files as this: myfilename.pdf and myfilename.json okay thanks. ...
- Mon Nov 16, 2020 9:40 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
- Sun Nov 15, 2020 1:26 pm
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
- Sun Nov 15, 2020 9:48 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
- Sun Nov 15, 2020 9:47 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
Re: Select a file from the beginning of a flow
One way is to embed the text file or the PDF as an Opaque dataset in the other file and in the script access that dataset. It will then be saved as a temp file that you can read from the script. For Example I have this flow where I want to opaque pickup a *.json file in a *.pdf file but it stucks b...
- Sat Nov 14, 2020 9:18 am
- Forum: LEGACY scripting
- Topic: Select a file from the beginning of a flow
- Replies: 20
- Views: 5458
Re: Select a file from the beginning of a flow
Branch of to one folder before the pdfToolbox element and then from that folder back to the folder before the script, then both the PDf and the TXT will be going in to the script. In the script you have to pick up both the PDF and the TXT file. How can I select the textfile and the pdf file in the ...
- Tue Sep 29, 2020 10:09 am
- Forum: LEGACY scripting
- Topic: Switch Webhooks
- Replies: 13
- Views: 3293
Re: Switch Webhooks
Okay, I have the Webserver up and running with the following javascript. function getQueryVariable(variable) { var query = window.location.search.substring(1); var vars = query.split("&"); for (var i=0;i<vars.length;i++) { var pair = vars[i].split("="); if(pair[0] == variable){return pair[1];} } ret...
- Mon Sep 28, 2020 4:20 pm
- Forum: LEGACY scripting
- Topic: Switch Webhooks
- Replies: 13
- Views: 3293
Re: Switch Webhooks
Your URL needs to include the data like what is suggested before. https://yoururl?jobnumber=123456&filename=GES.pdf&numberOfCopies=150 That will then be picked up on the webserver and from there you can send it to Switch. So you QR-code should include the URL with variables. There is a lot of info ...