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

Sharepoint List to Excel Spreadsheet to Mailchimp - Date Formatting

Hi,

 

I have been having trouble connecting a flow that when a new item is created in a Sahrepoint List, this updates all fields in Mailchimp. At the moment, flow only allows you to add a new subscriber in Mailchimp for First Name, Last Name and Email Address. I have found a solution using both flow and other automation tool.

 

Flow connects the Sharepoint List and adds a new row onto a table in Excel Online (Business) in One Drive. The other automation tool then links the excel table to Mailchimp and when a new row is created from the original flow in the table it then adds a new subscriber to Mailchimp with all related fields.

 

The problem is the format in the Sharepoint list for DOB is DD/MM/YYYY 00:00 which is pulled through to the Excel Online spreadsheet using Flow. However the other automation tool fails and said that the date format needs to be MM/DD. Does anyone know if there is any way in Flow that an action can be created to adjust the format of this field so that when it pulls it through to Excel it can be in the format required?

 

Ive tried to explain best I can. I am also a new user so please forgive me if im wrong.

 

Thanks

Natalie

4 REPLIES 4
Community Support Team
Community Support Team

Re: Sharepoint List to Excel Spreadsheet to Mailchimp - Date Formatting

Hi @Natalie_b06 ,

 

Could you share a screenshot on your current flow?

 

If you want the date time formatted to be ‘MM/DD’, please just insert a formatDateTime function in the datetime field.

 

Please check the following doc on the formatDateTime function for more details:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#f...

 

Best regards,

Mabel       

   

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Natalie_b06
Level: Powered On

Re: Sharepoint List to Excel Spreadsheet to Mailchimp - Date Formatting

Hi Mabel,

 

Here is a screenshot. It is the 'DOB' field that needs formatting to 'MM/DD' im not familar with expressions yet. Would I put the formatDateTime function in the DOB field?

 

Thanks

 

Untitled-1.jpg

Natalie_b06
Level: Powered On

Re: Sharepoint List to Excel Spreadsheet to Mailchimp - Date Formatting

Ive added 

format DateTime(triggerBody()?['DOB'],'MM/DD/YY')
into the DOB field and ran the flow and it is failing (see below):
Untitled-2.jpg
Community Support Team
Community Support Team

Re: Sharepoint List to Excel Spreadsheet to Mailchimp - Date Formatting

Hi @Natalie_b06 ,

 

The error message says that the provided value is of type Null. Please make sure DOB in the SharePoint list does have value.

 

Further, please modify you function into:

formatDateTime(triggerBody()?[‘DOB’],’MM/dd/yyyy’)

 

I have made the following test according to the screenshot, which is working successfully.

 

The function I am using in the Start field is:

formatDateTime(triggerBody()?['StartDate'],'MM/DD/YYYY')

 

An image for your reference

1.PNG2.PNG

 

Best regards,

Mabel         

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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 (4,837)