cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
krfajar
Helper III
Helper III

Convert Float to Integer Ms Flow in addDays Expression

I have column in SharePoint list with type data Number.

6.png

 

I want convert from float to integer, because showing error message at my flow:

4.png

 

 

 

 

Please Check My Flow:

7.png5.png

 

How to convert from type data Number to Float (base on to error message). Because I want create calculated Planned Due Date = addDays(utcNow() + estimated sailing in duration. Thanks

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @krfajar,

 

Does your Float number contain decimal places? If not, you could put the int() function into the second parameter of addDays() function:

addDays(utcNow(),int(variables('Float')),'yyyy-MM-dd')

Annotation 2020-08-14 094958.jpg

 

If it contains, you should remove the decimal part, for example:

first(split(string(variables('Float')),'.'))
addDays(utcNow(),int(outputs('Compose_2')),'yyyy-MM-dd')

Annotation 2020-08-14 132214.jpg

 

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

3 REPLIES 3
ChristianAbata
Super User II
Super User II

hi @krfajar please add int() and inside it your current expression like int('Here your current expression')



Did I answer your question? Please consider to Mark
my post as a solution! to guide others :winking_face:

Proud to be a Flownaut!


If you want you can follow me at www.christianabata.com Quieres contenido en español? Síguenos en Power Automate LA

Hi @

 

 

 

 

 

 

Hi @krfajar,

 

Does your Float number contain decimal places? If not, you could put the int() function into the second parameter of addDays() function:

addDays(utcNow(),int(variables('Float')),'yyyy-MM-dd')

Annotation 2020-08-14 094958.jpg

 

If it contains, you should remove the decimal part, for example:

first(split(string(variables('Float')),'.'))
addDays(utcNow(),int(outputs('Compose_2')),'yyyy-MM-dd')

Annotation 2020-08-14 132214.jpg

 

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
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

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

Top Solution Authors
Users online (95,548)