Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Unanswered

Post SharePoint list item to a specific Teams subchannel when a specific item from dropdown is selected

(0) ShareShare
ReportReport
Posted on by

Hello, I would like to post a SharePoint list item to a specific Teams subchannel depending on the selection the user has chosen from a dropdown. Does anyone know how this flow can be created?

  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at
    Re: Post SharePoint list item to a specific Teams subchannel when a specific item from dropdown is selected

    Hi @JenG 

     

    Based on the following:

    MicrosoftTeams.PostMessageToChannelV3("28d3ec1b-2f15-49c8-ac27-3f070a89a141",Dropdown1.SelectedText.id,{contentType: "html", content: "Hello World"})

     

    The parameters are the group ID, channel ID and the message content.

     

    GroupID

    I retrieved the group ID via teams, ellipses get link to channel and in the URL there is groupID=.....

     

    ChannelID

    For the channel ID's, I used a dropdown based on the expression MicrosoftTeams.GetChannelsForGroup which accepts a groupID too and returns a table of channels for that group.  You could save that expression to a collection, rather than use it on a dropdown and lookup based on your other dropdown values?  

     

    Message Content

    I just went with a basic message.  

    {contentType: "html", content: "Hello World"}

     

    HOWEVER!....

     

    I have just looked up the official docs and this is deprecated 😞 Microsoft Teams - Connectors | Microsoft Docs and the alternative Microsoft Teams - Connectors | Microsoft Docs does not give much away in terms of the parameters required.

     

    So I hooked up a flow as follows:

    DamoBird365_0-1647618355804.png

    Same idea with a drop down for the channel names and I pass the value dynamically.  You could also pass the message if you wanted.  Note my flow is called SendMessagefromPowerApps.

     

    SendMessagefromPowerApps.Run(Dropdown1.SelectedText.id)

     

    Damien

     

     

     

     

  • JenG Profile Picture
    on at
    Re: Post SharePoint list item to a specific Teams subchannel when a specific item from dropdown is selected

    Thank you for replying. I have the Teams connector set. However, I am not sure how to do the rest of what you listed. Can you please break it down further for me?

  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at
    Re: Post SharePoint list item to a specific Teams subchannel when a specific item from dropdown is selected

    Hi @JenG 

     

    Potentially no need for a flow for this one.  There is a Teams connector.

     

    If you add the connector:

    DamoBird365_0-1647461180662.png

     

    You can post to a team with the following expression:

     

    MicrosoftTeams.PostMessageToChannelV3("28d3ec1b-2f15-49c8-ac27-3f070a89a141",Dropdown1.SelectedText.id,{contentType: "html", content: "Hello World"})

     

    I created a drop down of channels for a specific group as follows:

    DamoBird365_1-1647461324744.png

     

    MicrosoftTeams.GetChannelsForGroup("28d3ec1b-2f15-49c8-ac27-3f070a89a141").value

     

    The button obviously calls the PostMessageToChannelV3 expression.

     

    Damien

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

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,702 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,015 Most Valuable Professional

Leaderboard