Rename Outlook excel attachment while save in desktop

Any Easiest way to rename and save Outlook excel attachment (.xls /.xlsx /other excel format) in Desktop.

For Ex:

I received an email with excel attachment Named as “891”, i need to save this attachment in desktop as “AttachedFile”

@Chandru_Ganapathi,

After saving the attachment then use MoveFile activity to rename the file.

@lakshman

Currently i am using that only, just want to know any way to save directly from outlook.

And while using MoveFile we need name should be constant, for mine attachment name is not constant, its dynamic one.
Is any way to rename any format excel file to “AttachedFile” with same format using “MoveFile”

@Chandru_Ganapathi,

Is there any inter link between mail subject and it’s attachment ?

@lakshman

Yes, subject will contain “Report-891” with attachment name as “891”

@Chandru_Ganapathi,

Split mail subject and get that number. Here, it is 891. Then try below one:
Str = Directory.getFiles(path,“891”)
Then use MoveFile activity

@Chandru_Ganapathi,

Please check below thread. May be it will help to you.

How to rename the attachment file after downloading from outlook.? - #6 by Florent_Salendres

1 Like