Im trying to inject files via my metadatas I have some issues
when I use the built-in inject tool I can import only the first file (I don't know if my XML is well writed ) when I choose the "files" node switch don't seem to read through the entire node
Code: Select all
Xml:
<files>
<file>
<path>C:/Users/flprint-switch/Desktop/checker/ORDxxxxxxx/ORDxxxx/docs/xxxxx1.pdf</path>
<path>C:/Users/flprint-switch/Desktop/checker/ORDxxxxxxx/ORDxxxx/docs/xxxxx2.pdf</path>
</file>
</files>
Code: Select all
function jobArrived( s : Switch, job : Job )
{
var dataset = job.getDataset('Xml');
//var path = dataset.evalToString('/order/files');
var dummyPath =( 'C:/Users/flprint-switch/Desktop/checker/ORDxxxxxxxx/ORxxxxxxx/docs/xxxxx1.pdf'); // for testing
job.sendToSingle(dummyPath);
}
The issues are :
the injected file is cleared from his original location(we have to keep the customers files )
the original name and extention are replaced or disapear
Only one file is imported
I can figure this out hope you will help me

Best regards
