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

Dynamics 365 Update Record - Add Date Time fields + more

welcome.

scenario is quite simple, but i am quite new to MS Flow.

 

Dynamics 365 Crm, Invoice Entity.

We have fields:

  • Days Until Payment - Whole Number
  • Invoice Date - Date Time

when Condition is met i want to add a fields into a Date Time field: Invoice Date + Days Until Payment + 3 extra days.

 

i am not able to add those fields.

 

thanks  for help

1 ACCEPTED SOLUTION

Accepted Solutions
v-lin-msft
Level 10

Re: Dynamics 365 Update Record - Add Date Time fields + more

Hi @Toms,

 

You can have a try with the following configuration.

I used fields of SharePoint instead, and create fields Day Until Payment, Invoice Date and Delay Date in a list.

Annotation 2019-05-22 132714.png

Day Until Payment, Number;

Invoice Date,  Date time;

Delay Date, Date time.

And your requirement is that adding the sum of "Invoice Date + Days Until Payment + 3 extra days" into field Delay Date. You can reference to these functions:

functions-reference#addDays

functions-reference#int

functions-reference#add

 

Step1: Get the result of the sum of "Day Unitil Payment" and "3", and convert them from floating to integer.

int(add(triggerBody()?['DayUntilPayment'],3))

Step2: Add the function addDays(InvoiceDate,integer,Format of Date)

addDays(triggerBody()?['InvoiceDate'],outputs('Compose'),'MM-dd-yyyy')

Step3: Add the result into your field Delay Date or other name.

 

You can put the function in the Expression.

Annotation 2019-05-22 132335.png

Please have a try with it and I hope it will help you.

Best Regards,

Community Support Team _ Lin Tu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-lin-msft
Level 10

Re: Dynamics 365 Update Record - Add Date Time fields + more

Hi @Toms,

 

You can have a try with the following configuration.

I used fields of SharePoint instead, and create fields Day Until Payment, Invoice Date and Delay Date in a list.

Annotation 2019-05-22 132714.png

Day Until Payment, Number;

Invoice Date,  Date time;

Delay Date, Date time.

And your requirement is that adding the sum of "Invoice Date + Days Until Payment + 3 extra days" into field Delay Date. You can reference to these functions:

functions-reference#addDays

functions-reference#int

functions-reference#add

 

Step1: Get the result of the sum of "Day Unitil Payment" and "3", and convert them from floating to integer.

int(add(triggerBody()?['DayUntilPayment'],3))

Step2: Add the function addDays(InvoiceDate,integer,Format of Date)

addDays(triggerBody()?['InvoiceDate'],outputs('Compose'),'MM-dd-yyyy')

Step3: Add the result into your field Delay Date or other name.

 

You can put the function in the Expression.

Annotation 2019-05-22 132335.png

Please have a try with it and I hope it will help you.

Best Regards,

Community Support Team _ Lin Tu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

firstImage

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

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

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 Solution Authors
Top Kudoed Authors
Users online (5,519)