Skip to main content

Notifications

Power Automate - Building Flows
Answered

Covert Object into Array??

(0) ShareShare
ReportReport
Posted on by 252

Hi All,

 

I have a flow which takes information from the Description of a Task and puts it into a Teams Chat.

The task description looks like this:

Skybluekid_0-1690292585809.png

I have managed to remove the Not Relevant part, but when I place the rest in the teams message it comes out like this:

["Part Number : Description","Part Number : Description"]

 

What I would like is to have it:

Part Number : Description

Part Number : Description

 

Any help would be appreciated

  • Skybluekid Profile Picture
    Skybluekid 252 on at
    Re: Covert Object into Array??

    Thank you very much

  • Verified answer
    Re: Covert Object into Array??

    Hi @Skybluekid ,

     

    Sorry, my mistake.

    Please try this

    replace(replace(replace(replace(string(variables('var')),'[',''),']',''),',','<br>'),'"','')
    vxiaochenmsft_0-1690358761477.png

     

    vxiaochenmsft_1-1690358773863.png

     

     

    Best Regards,

    Wearsky

  • Skybluekid Profile Picture
    Skybluekid 252 on at
    Re: Covert Object into Array??

    Hi

    I have tried the solution.  when I post it to Teams it comes out as 

     "Part Number : Description" "Part Number : Description"

  • Re: Covert Object into Array??

    Hi @Skybluekid ,

     

    Please try to convert the variable from array to string.

    Sample:

    vxiaochenmsft_0-1690334900327.png

    replace(replace(replace(string(variables('var')),'[',''),']',''),',',decodeUriComponent('%0A'))
    vxiaochenmsft_1-1690334923708.png

     

    Best Regards,

    Wearsky

  • Skybluekid Profile Picture
    Skybluekid 252 on at
    Re: Covert Object into Array??

    Alternatively, how would I get rid of the Not Relevent section from the original Description

  • Skybluekid Profile Picture
    Skybluekid 252 on at
    Re: Covert Object into Array??

    This what I have in my flow

    Skybluekid_0-1690297472309.png

     

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,445

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,741

Leaderboard