Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Using Flows
Answered

Convert string from array to integer

(0) ShareShare
ReportReport
Posted on by 5

Hello Community,

 

I'm parsing a table out from a mail with power automate. I just need to get the last item of the table. I managed to get this specific row and manage do store it into a variable.

But i failed to convert it to integer.

My data can takes several forms like : 480 000 or just 0 or -0,03 or 452 000,23.

All i want is to convert the string into integer in order to make some logical test with the data after.

 

Today i have error when compose data with int() formula.

 

Jouv_1-1634547248010.png

 

Jouv_2-1634547292456.png

 


 

 

Best regards,

 

Kair0

  • Verified answer
    v-bofeng-msft Profile Picture
    on at
    Re: Convert string from array to integer

    Hi @Jouv :

    The key is that 125.2, -0.03 and other decimal values are all floating-point numbers, they are not integers.vbofengmsft_0-1634626713903.png

    You'd better try:

    float(trim(output(var)))

    Best Regards,

    Bof

  • Jouv Profile Picture
    5 on at
    Re: Convert string from array to integer

    Hello @Mira_Ghaly ,

     

    trim does not the same thing like in excel. It just remove blank space before and after not between.

    when my variable is equal to 125,2 or -125,25 or -0,03, int(trim(output(var))) will fail.

  • Mira Ghaly Profile Picture
    11,409 Super User 2025 Season 1 on at
    Re: Convert string from array to integer

    @Jouv 

    Did you try to use the trim expression before converting to INT?

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,524 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,906 Most Valuable Professional

Leaderboard

Featured topics

Restore a deleted flow