Get email addresses from Excel Attachment and Send emails

Copper Contributor

Pls need help creating a Power Automate flow: When I receive a certain email (Outlook 365) with an Excel attachment, get the email addresses from column D in the Excel attachment, then forward the original email I received to that list of email addresses.

3 Replies

Hi @rdietz65 , your trigger would contain the filters to recognize the particular characteristics of the incoming email. You would then need a 'get items' action to retrieve the matching record from the SharePoint list using the query attributes. You can set the 'get items' action to retrieve a single record.

@jonlake "Sharepoint"? I'm not using a Sharepoint list though. It's an Excel attachment in an email. I need PA to "read" the Excel attachment and get the email addresses from a specific column, then forward my original email to those email address recipients that were in the Excel attachment.

HI@rdietz65 , you would first need to save the spreadsheet to (presumably) a temporary folder, and assign the name of the spreadsheet to a variable so that you can refer to it correctly in a 'List rows present in a table' action. Searching through records in Spreadsheets will only be possible if the data is formatted as a table. If that's not the case then you won't be able to search it using PA and you'll need to consider ways to force the formatting before PA is activated. I've done that previously using VBA script, triggered in Outlook (desktop). The product of that action ends up in a syn'd folder (OneDrive or SharePoint), allowing PA to trigger a Flow.

If we assume the records are formatted within table you can then loop through the resulting items (from the 'List rows present in a table' action) and forward an email.