Create new file with folder name in it

Hello,

How can I create this file from scratch with no inline rename option: "parent folder name - test.xlsx"
In other words, the excel file should have the parent folder name in it followed by a fixed string (e.g. "- test")?
For a folder called "John Doe" the created file should be "John Doe - test.xlsx".

Many thanks,
Val

filetype new=.xlsx newname="norename:{sourcepath|nopath|noterm} - test"

Thank you very much for the fast answer. :slight_smile:

One more thing: How can I copy a template file from a fixed location
"D:\Clients---CC Dampness Report.docx"
and rename it to "Dampness Report {parent} to include the directory name in it?
For John Doe directory the template file would be copied over to (here) and renamed to "Dampness Report John Doe".
Thank you again.

copy "D:\Clients---CC Dampness Report.docx" here as "Dampness Report {sourcepath|nopath|noterm}.docx"

Thank you very much, much appreciate it again. :slight_smile: Great support. :slight_smile:

2 Likes