Expand my Community achievements bar.

Write document to a dynamic sub directory

Avatar

Former Community Member

Hello,

I am using the Write Document (FileUtilService) to to write some attachments to a static directory by using the below statement and it works just fine.

Input - Pathname Pattern (XPath expression)

concat("D:\MyDir\", getDocAttribute(/process_data/attachments[number(/process_data/@attachCount)],"wsfilename"))

Now I would like to them to a dynamic sub-directory like "D:\MyDir\XXXX\"   where XXXX is number that dynamic change by Process ID.

I try this:   concat("D:\MyDir\process_data/@id$}\", getDocAttribute(/process_data/attachments[number(/process_data/@attachCount)],"wsfilename"))

but it does not work right.

Can any one please adivse.

Thanks in advance,

Han Dao

2 Replies

Avatar

Level 10

Invalid destination Directory!

You are attempting to create a sub-directory with illegal character name.

The correct XPATH must be:

Try this and let me know

Nith