cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Raffolution
Regular Visitor

Email attachments

Hi guys,

We have a job system that receives supplier invoices by email and the processes them automatically.

The system will not accept emails that have more than one file attached.

I want to auto rename all attachments received in our accounts inbox to domain name of sender and date then save to a sharepoint folder.

I then want the files to be sent to the job system by email one file at a time.

Is this possible?

I have tried and failed
1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Re: Email attachments

Hi @Raffolution ,

 

The expression for the domain should as below:

last(split(first(split(triggerBody()?['from'],'.')),'@'))

 

1.png

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
sudharsan1985 Post Patron
Post Patron

Re: Email attachments

Hi @Raffolution 

You can export the file or contents from email and save it in SharePoint with a new name and then you can send an email to the users. This is possible in Power Automate. Please post your flow screenshot and let us see the issue.

 

Hope it helps, please like it or mark it as a solution if it resolves ur clarification or issue
-Sudharsan K...

Community Support
Community Support

Re: Email attachments

Hi @Raffolution ,

 

Could you please share an example of the domain name of the sender?

 

You could create two flow to achieve the requirement, one for create the file in the library folder:

1.png

And another for send the email with the file when the file is created in the library:

2.png

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Raffolution
Regular Visitor

Re: Email attachments

Hi,

 

This worked perfect except I need to identify what supplier the invoice came from.

 

I was hoping that the file when getting renamed could have the domain name in

 

eg. invoice from sales@microsoft.com the file would be renamed microsoft.{date}

 

Thank you,

Community Support
Community Support

Re: Email attachments

Hi @Raffolution ,

 

The expression for the domain should as below:

last(split(first(split(triggerBody()?['from'],'.')),'@'))

 

1.png

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Automate Community!

firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (6,646)