Hello,
I'm trying to build a flow where whenever a new email comes in that has an attachment (.xlsx, .csv, .txt, etc.) and has a variable = "XYZ" to save the attachment(s) to a specific file folder, "XYZ_COMPANY". So far, the flow works for the first array (I hope I'm using the correct terminology) under "XYZ", but will not work for the second, "ABC". When an email with variable = "ABC" comes in with attachments, the flow will save the attachments to file folder "XYZ_COMPANY", when it should save the attachments to "ABC_COMPANY".
{ "foldermapping": [ { "FolderNameField": "XYZ_COMPANY", "sender": "XYZ" }, { "FolderNameField": "ABC_COMPANY", "sender": "ABC" } ] }
variables('FolderName')['foldermapping'][0]['FolderNameField']
first(split(last(split(triggerBody()?['From'],'@')),'.com'))
variables('FolderName')['foldermapping']
item()['sender']
Folder path:
\\folder_path\ABC_COMPANY\
The Output under Folder path is generated from 'ComposeFolderName'
The Output under File name is generated from 'Compose-ConcatFullFileName'
This is my first post, so I hope I provided enough detail and explained the flow ok.
Many Thanks,
NT22
Hi @Anonymous,
Thank you for your sharing, I believe many peope would benifit from it.
Best regards,
Alice