cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
wslayton
Level: Powered On

Output SharePoint 365 list to CSV file using Flow: How can I add the file extension to the filename (.csv)?

I can pull only the list fields I need, put them into a file, attach to an email, and then send the email. But when I click on the eMail attachment it won't open in Excel. If I try to "Save As" and then open with Excel, it puts all columns into the "A" column on each row. But... if I add ".csv" when doing the "Save As" and double-click the saved file, it will open correctly in Excel.

 

I want to add the file extension .csv automatically in the Flow rather than have the user enter it manually at the "Save As".

 

Any ideas?

 

Bill

1 REPLY 1
Super User
Super User

Re: Output SharePoint 365 list to CSV file using Flow: How can I add the file extension to the filename (.csv)?

Hi @wslayton , i see you in other thread 😄

 

First, thanks to open a new thread, this helps the community!

 

We have a trick to use dynamic content + expressions7

 

  1. Open the expression panel
  2. Type an 'a'
  3. Click in DynamicField panel
  4. Choose the DynamicField
  5. Remove the 'a' typed
  6. Use funcions with this field 
  7. Be happy Smiley Very Happy

 

To complete your quest you can use this expression in Attachament name:

 

 

concat(triggerBody()?['Title'],'.csv')

In this case I concat the Title of item that triggered Flow, (using in this sample SharePoint 'When an item was created' trigger)

 

 

Best Regards,

Gustavo Moraes

Community Super User
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. And give me a kudo to make me more happy!


Did I answer your question? Mark my post as a solution!

Gustavo Moraes, o astronauta brasileiro do Flow!


Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

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

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors (Last 30 Days)
Users online (6,005)