I want that the BOT save the attachment from the Mail and start the process with this file.
This means that I can’t set a fixed path in e.g the Read Range activity, right? Because then it would work always with the same file…
The files always have the same name the only difference is the weeknumber at the end of the file (e.g Fcst cw27, Fcst cw28, …)
Hello Loons,
We talked something about this before (i will find the topic later).
So, when you download the attachment it has a fixed name (you can get this name).
After that, you can rename the file with something dynamic, something like current date + attachment name.
After that you can store that value in a variable and use Read Range activity or any other reading activity with that dynamic variable.
Hi @Loons
Yes so its better to get the last created file once after downloading the attachment and to get that outfilepath = Directory.GetFiles(“yourFolderPath”,"*.yourfileextension”,SearchOption.AllDirectories).OrderByDescending(Function(d) New FileInfo(d).CreationTime)(0)