Search found 414 matches

by jan_suhr
Thu Apr 01, 2021 7:49 am
Forum: Node.js scripting
Topic: Issue With job.getPath()
Replies: 2
Views: 176

Re: Issue With job.getPath()

You don't have any job.getPath() function in Node.js for Switch. BTW the manual you link to is a really old one from Switch 11 and for the old Legacy scripting. Try this one which have an example on how to get the job path. https://www.enfocus.com/manuals/DeveloperGuide/SW/20/home.html#en-us/common/...
by jan_suhr
Wed Mar 31, 2021 7:51 am
Forum: Flows
Topic: Word configurator
Replies: 2
Views: 1198

Re: Word configurator

How does the PDF look if you save as PDF from within Word?
by jan_suhr
Fri Mar 12, 2021 3:34 pm
Forum: Flows
Topic: How to set text file contents as email body
Replies: 11
Views: 1401

Re: How to set text file contents as email body

I see that you are from Sweden, call me at 0707490774 and I can take a look at it.
by jan_suhr
Thu Mar 11, 2021 6:00 pm
Forum: Flows
Topic: How to set text file contents as email body
Replies: 11
Views: 1401

Re: How to set text file contents as email body

In your own HTML-template you insert Switch variables with the information you want to display in the email.
by jan_suhr
Wed Mar 10, 2021 11:00 am
Forum: Flows
Topic: Calculate date from [weeknumber]-[weekdaynumber]?
Replies: 3
Views: 340

Re: Calculate date from [weeknumber]-[weekdaynumber]?

It can be even simpler

Code: Select all

const moment = require("moment");

var myDay = moment("2021-W05-4").format("YYYY-MM-DD");

console.log(myDay);
In this case the 05 and 4 will be replaced by variables or maybe just one variable for the 05-4
by jan_suhr
Tue Feb 23, 2021 8:55 pm
Forum: Appstore
Topic: String Replace
Replies: 3
Views: 1083

Re: String Replace

Great
by jan_suhr
Tue Feb 23, 2021 6:50 pm
Forum: Appstore
Topic: String Replace
Replies: 3
Views: 1083

Re: String Replace

Have you tried \n
by jan_suhr
Mon Feb 22, 2021 7:36 am
Forum: Flows
Topic: Moving big files
Replies: 5
Views: 599

Re: Moving big files

You can split the flow to run only the XML-files through another Submit hierarchy element.
by jan_suhr
Mon Feb 08, 2021 3:03 pm
Forum: Flows
Topic: Send processed files to path in metadata
Replies: 7
Views: 1068

Re: Send processed files to path in metadata

I can be done without a script, but you can't use S:\\Customer\\order\\Test if it is a mounted volume to the Switch server.
You have to use \\MYSERVER\Customer\order\Test as the path in the Archive Hierarchy
by jan_suhr
Mon Feb 08, 2021 1:36 pm
Forum: Flows
Topic: Send processed files to path in metadata
Replies: 7
Views: 1068

Re: Send processed files to path in metadata

Don't you have it in your script?

If you have it the Dataset from the XML you have you specify it as \\MYSERVER\Folder\Order\jobfile
by jan_suhr
Mon Feb 08, 2021 1:07 pm
Forum: Flows
Topic: Send processed files to path in metadata
Replies: 7
Views: 1068

Re: Send processed files to path in metadata

Have you tried to escape the backslashes i.e. S:\\Customer\\order\\Test
by jan_suhr
Sat Feb 06, 2021 9:27 am
Forum: Flows
Topic: pdftk and cat command
Replies: 17
Views: 16994

Re: pdftk and cat command

You run the .bat in the Execute Command as the Command or Path property. In argument you just put "%1" "%2"
by jan_suhr
Thu Jan 28, 2021 5:35 pm
Forum: Flows
Topic: Web Service API - good practices
Replies: 4
Views: 1233

Re: Web Service API - good practices

To clear this a bit. The unique prefix is a way for Switch to keep track of every file that is routed through Switch. This mean that if you enter one file in a flow it will get a prefix ID. Then you have a folder with three outgoing connections which means that switch has to make two copies of the f...