Reputation: 778
I have a template I have been using with great success in power automate flows.
my apply to each segment is as follows
this saves the file like...
my issue is I do not want the '_2023-03-09-0103' to show up in the sharepoint loaded attachment. I have tried multiple online references using split, and trigger and cannot figure out how to make the name of the SharePoint file 'OrigamiUserList.xlsx'. I know it lives in the ShrePoint - CreateFile - FileName field, I just cannot figure out the correct syntax to make it work. When I replace the provided 'Attachments Name' option with 'OrigamiUserList' the program uploads a blank page with the name but not in excel format and with no data. Thank you in advance
Upvotes: 0
Views: 755
Reputation: 11262
A split function should do it for you. I'm running a little blind here and can't reproduce your exact requirement but this shows how it can be done ...
Flow
The expression in the second step is ...
concat(split(variables('File Name'), '_')[0], '.xlsx')
Obviously, that could be improved given I am implying the extension but if it's always .xlsx
then it will always work.
Result
Upvotes: 0