Task Is : Download all email attachments into folder.
Issue is : It is downloading extra images (Company’s logo, or any other image attached at the end of the email).
I do not want to download an extra image Like LOGO and etc… Can anyone help me on this?
You can simply download the attachment as its with the Company logo ect
After the save attachment sequence. Drive the for each loop on that directory where you have saved the attachment. and use the below if condition
If = path.GetFileName(item).ToString.EndsWith(".PNG")
PNG - Based on image and logo format you can change it.
Then use the delete activity in the ‘Then’ sequence.
after that Image file will be deleted from that folder.
@Gokul001 I understand this scenario but my attachments also comes as an .PNG or . GPEG sometimes.
So, In this case If I try to delete any images it will delete my attachments as well.
@THIRU_NANI Thanks for sharing. I am saving attachments into folder but I want to delete an extra Logo images.
Can you help me out on this?
This thread will help you to achieve your requirement
I want to save email attachments which does not include signature images. My attachments contains different types of file. Can some one help me with this?
For Each File in Folder Activity → Uipath.System.Activities
CurrentFile.Extension.Equals(".jpeg") or CurrentFile.Extension.Equals(".png")
Refer to the screenshot
Hope it will solve your query
@Gokul001 Thanks for sharing but my question is I can receive PNG and GPEG as attachments also which is required to download but signature or logo images I do not want to download.
After saving the attachments, go to the folder where the attachments are downloaded and check if all the unwanted images contains common names eg:image01, image02 .If there are such match, then select the all specific files that contains the name ‘images’ and delete them.