I have a folder with a lot of different file types being uploaded. I have sorted out the PDF but I would like to send a mail with all the other files just like a list like this:
- - - - - - - - - - - - - - - - - - - - - - - -
These files have been uploaded to your server:
image1.png
image2.jpg
textdocument.txt
photo4.tif
- - - - - - - - - - - - - - - - - - - - - - - -
Also want it to batch the files - not an email for every file...
I tried to use the "Assemble job" and set the value "After N minutes" to "2" and then the "Orphan timeout (minutes) to "3". So if there are no new files within 2 minutes it collect those into the email.
(If Im thinking right).
Or does anyone else having any other good examples on this?
Best regards
How to display incoming files from a folder?
-
- Newbie
- Posts: 18
- Joined: Mon May 26, 2014 3:50 pm
How to display incoming files from a folder?
[Job.NestedName] will give you a list of all the files in the job folder after the Assemble job. If there are subfolders the formatting may not be what you want and you may have to revert to a script expression. Try {Job.NestedName] first to see if it suits your needs.
Freddy
Freddy
-
- Newbie
- Posts: 18
- Joined: Mon May 26, 2014 3:50 pm
How to display incoming files from a folder?
Well. It is almost ok...
I got this message like this:
------------------------------
Files uploaded…
Job001;• testfile1.jpg;• testfile2.jpg;• testfile3.jpg;• testfile4.jpg
Email was triggered by this folder :
Job001
testfile1.jpg
testfile2.jpg
testfile3.jpg
testfile4.jpg
------------------------------
Now I have set the "Indent" to "• ". But they all come on one line... I would prefer them on one row for each file. I have tried a few "Actions" and also tried "", "r" and "nr" without working.
The last bottom of the message is something that is pre-built from Enfocus and lists them on sinlge rows...
Also... is it possible to rename jobfolder to date instead?
I got this message like this:
------------------------------
Files uploaded…
Job001;• testfile1.jpg;• testfile2.jpg;• testfile3.jpg;• testfile4.jpg
Email was triggered by this folder :
Job001
testfile1.jpg
testfile2.jpg
testfile3.jpg
testfile4.jpg
------------------------------
Now I have set the "Indent" to "• ". But they all come on one line... I would prefer them on one row for each file. I have tried a few "Actions" and also tried "", "r" and "nr" without working.
The last bottom of the message is something that is pre-built from Enfocus and lists them on sinlge rows...
Also... is it possible to rename jobfolder to date instead?
-
- TOP CONTRIBUTOR
- Posts: 628
- Joined: Mon Nov 29, 2010 8:45 pm
- Location: Alpharetta GA USA
- Contact:
How to display incoming files from a folder?
here's a script expression to grab the names of files in a job folder and return them as a message that could be used with Email body property.
var b = "The following files have been uploaded to the servernn";
var d = new Dir(job.getPath());
var e = d.entryList("*", Dir.Files|Dir.NoDotAndDotDot, Dir.Name);
for (var i=0;i<e.length;i++)
b += e + "n";
b;
var b = "The following files have been uploaded to the servernn";
var d = new Dir(job.getPath());
var e = d.entryList("*", Dir.Files|Dir.NoDotAndDotDot, Dir.Name);
for (var i=0;i<e.length;i++)
b += e + "n";
b;
-
- Newbie
- Posts: 18
- Joined: Mon May 26, 2014 3:50 pm
How to display incoming files from a folder?
Hm, Im not sure where in the process to put that expression...
Should it be on the "send email" or on the folder before that and include body text to the email?
Tried both but got errors.
Should it be on the "send email" or on the folder before that and include body text to the email?
Tried both but got errors.
-
- TOP CONTRIBUTOR
- Posts: 628
- Joined: Mon Nov 29, 2010 8:45 pm
- Location: Alpharetta GA USA
- Contact:
How to display incoming files from a folder?
Sorry, I had a typo in my example. Fixed