cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Dan24
Frequent Visitor

Building a Flow to get an excel attachment from an email, upload to One Drive Folder and time stramp it.

Hi All

 

Please advise if you can assist on the below which i am trying to create in Flow: 

 

When a new email arrives in my Outlook 365 Inbox with an excel attahcment i would like flow to extract that excel attachment and upload it to my One Drive Folder called "Oracle Excel". Sometimes i am dealing with multiple excel files with different or similar names and i would like to find a way to put a date and time in the excel attachment name like "Oracle Report 18/05/2021 6:50pm".

 

I would also like to make sure that files with similar names should not overwrite each other hence i woud like to put a date and time stamp. Also the date and time needs to be in Australian Eastern Standard Time. 

 

I would like for the timestamp date and time to appear at the end of the attachment title for example it should be "Oracle Report - 18/05/2921 6:50pm" and not "18/05/2021 6:50pm Oracle Rreport.xls"

 

Please advise if you can assist.

1 ACCEPTED SOLUTION

Accepted Solutions
v-duann-msft
Community Support
Community Support

Hi @Dan24 

 

Thank you for posting.

 

According to your description, you would like to add time stamp into file name in ‘AUS Eastern Standard Time’. If any misunderstanding, please kindly let me know.

 

As per my test, we can achieve most of your requirements including add time stamp and show it as AUS Eastern Standard Time. However, we can’t insert special characters like ‘:’ and ‘/’ into filename. That is not supported right now in sharepoint. All unsupported characters will be automatically replaced by ‘_’. So we can't use format like that:18/05/2921 6:50pm.

v-duann-msft_0-1621494400321.png

Restrictions and limitations in OneDrive and SharePoint - Office Support (microsoft.com)

 

Instead of the point I mentioned above, we can reach your goal using below flow:

v-duann-msft_1-1621494400327.png

 

Flow in detail:

v-duann-msft_2-1621494400331.png

 

Convert to AU Eastern timezone: convertTimeZone(utcNow(),'UTC','AUS Eastern Standard Time','dd/MM/yyyy HH:mm')

v-duann-msft_3-1621494400333.png

 

Insert date&time to file name :replace(outputs('Get_Attachment_(V2)')?['body/name'],'.',outputs('Compose'))

v-duann-msft_4-1621494400337.png

 

When I send email with 4 attachments and 2 of them are excel, the flow goes and only excel files copied to onedrive:

v-duann-msft_5-1621494400338.png

 

v-duann-msft_6-1621494400342.png

 

v-duann-msft_7-1621494400343.png

 

https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/default-time-zones

 

 

Hope the content above may help you.

 

Best regards,

Anna

View solution in original post

2 REPLIES 2
v-duann-msft
Community Support
Community Support

Hi @Dan24 

 

Thank you for posting.

 

According to your description, you would like to add time stamp into file name in ‘AUS Eastern Standard Time’. If any misunderstanding, please kindly let me know.

 

As per my test, we can achieve most of your requirements including add time stamp and show it as AUS Eastern Standard Time. However, we can’t insert special characters like ‘:’ and ‘/’ into filename. That is not supported right now in sharepoint. All unsupported characters will be automatically replaced by ‘_’. So we can't use format like that:18/05/2921 6:50pm.

v-duann-msft_0-1621494400321.png

Restrictions and limitations in OneDrive and SharePoint - Office Support (microsoft.com)

 

Instead of the point I mentioned above, we can reach your goal using below flow:

v-duann-msft_1-1621494400327.png

 

Flow in detail:

v-duann-msft_2-1621494400331.png

 

Convert to AU Eastern timezone: convertTimeZone(utcNow(),'UTC','AUS Eastern Standard Time','dd/MM/yyyy HH:mm')

v-duann-msft_3-1621494400333.png

 

Insert date&time to file name :replace(outputs('Get_Attachment_(V2)')?['body/name'],'.',outputs('Compose'))

v-duann-msft_4-1621494400337.png

 

When I send email with 4 attachments and 2 of them are excel, the flow goes and only excel files copied to onedrive:

v-duann-msft_5-1621494400338.png

 

v-duann-msft_6-1621494400342.png

 

v-duann-msft_7-1621494400343.png

 

https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/default-time-zones

 

 

Hope the content above may help you.

 

Best regards,

Anna

View solution in original post

Dan24
Frequent Visitor

thanks very much! 

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,026)