I’m going through the module about email automation and am trying to get emails from an inbox and save them to my drive in sorted folders. I’m using the ‘Save Mail Message’ activity, but it doesn’t work like I would expect.
When I read the documentation for ‘Save Mail Message’ it says that folders will be created if they don’t exist. In my case, it writes 'Could not find part of the path ‘C:\users[…]\Destination folder\Sorted Folder Name\Name of the File’.
And I’m thinking - “Yeah, that’s kinda what you’re supposed to create…”
My path looks like this:
“Sorted emails/” + mail.Sender + “/” + mail.subject
Can anyone tell my why it doesn’t just create the missing folders?
Workaround: Check the folder with a Path Exists activity, evaluate the output boolean with an If activity and use the Create Folder activity to create the folder dynamically yourself.
Thank you for taking a look at it. It’s good to know it’s not just me being dumb. I had thought of doing the workaround but thought it shouldn’t be necessary. I’ll try it out!
Once again thank you for reporting the potential bug. Our team had a look and the upcoming version of the Mail activity package will address this issue and the activity will create the folders for you.
The version of the package that will include the fix will be UiPath.Mail.Activities 1.11.1 or greater.