cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
vradley
Frequent Visitor

Inserting a list from Excel in Choice Options of Adaptive Card in Teams

Hi, 

 

I have an Excel Spreadsheet where there is a table. In sheet 1, the Table has many columns. I am interested in inserting all rows of one column as options in a choice of an Adaptive Card. 

 

I am using "List Rows in a Table" so that the flow knows has the data of what I need to insert in the adaptive card. I would need help inserting the Dynamic content (i.e. all cells in the column called Project Name of the Table in Sheet 1 of my spreadsheet) into the JSON of the adaptive card so that the user can choose, from a drop down, the project they are dealing with. 

 

Thanks. 

vradley_0-1598012330184.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Yutao
Microsoft
Microsoft

Hello @vradley ,

 

You may need to do a bit string manipulation before composing the Adaptive Card message payload.

 

Here is my test flow that simulates a similar scenario:

Yutao_0-1599151498951.png

Yutao_1-1599151555791.png

 

Basically I needed to compose and concatenate each cell data into the right format then insert into the Adaptive Card Message body.

 

I also needed to remove the trialing comma from the concatenated string to make it a proper JSON blob (the expression I used in the Adaptive Card Message):

substring(variables('choices'),0,sub(length(variables('choices')),1))

 

Hope this helps!

 

Yutao

View solution in original post

2 REPLIES 2
Yutao
Microsoft
Microsoft

Hello @vradley ,

 

You may need to do a bit string manipulation before composing the Adaptive Card message payload.

 

Here is my test flow that simulates a similar scenario:

Yutao_0-1599151498951.png

Yutao_1-1599151555791.png

 

Basically I needed to compose and concatenate each cell data into the right format then insert into the Adaptive Card Message body.

 

I also needed to remove the trialing comma from the concatenated string to make it a proper JSON blob (the expression I used in the Adaptive Card Message):

substring(variables('choices'),0,sub(length(variables('choices')),1))

 

Hope this helps!

 

Yutao

Rushi_Chandak
Helper I
Helper I

I Have Done the Same, Just Done For The Outlook Adaptive Card. 

But In the result i get Nothing

Rushi_Chandak_0-1650950464655.png

Anyone Please Suggest How to work on it.. 

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Users online (2,686)