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

Teams not passing correct Channel ID to Canvas app

Hi All, 

We have built a canvas app and deployed it on multiple Microsoft Teams Channels. On  App start up we have used the Param("channelId") to get the channel ID passed from Teams and use it in application logic.  The first time the app is opened through teams everything works as expected. 

 

The issue happens when a user switches to a different teams channel. We can see that the query string is passing the correct (updated) channel id like this 

 
 

querystr.PNG

 

but Param("channelId") still gives us the old channel id. (I have placed the channel id on the first page of the canvas app)

 

screen channel id.PNG

If we refresh the teams page (When using Teams through browser) the id gets corrected. If we use the desktop version of the Teams app we would have to log out and log back in to get the correct ID. 

 

Looks like Teams is doing some cache somewhere but i cant figure out how to fix it. Any help would be appreciated. 

 

Thanks

2 REPLIES 2
JayMagness
Super User
Super User

HI,

 

I personally develop to the Web browser for the most part. There is still a lot of integration happening at Microsoft on Desktop teams integration. As a rule Web teams will allow the application to run a little faster also. as an example Teams desktop will not pass location even though both power apps and teams ask for permission to use the option on load, and the web version works perfectly.

PowerAppsx23
Frequent Visitor

Thanks @JayMagness for your reply. I just need it to work with either one at this stage.  Would you have any idea as to why the correct id is not passed in the first instance?

 

Someone suggested there might be a setting in Teams Admin to turn off caching to have a temporary fix but I cannot find any option for it. 

Helpful resources

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

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

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

Power Apps June 2021

June Power Apps Community Call

Did you miss the call? Check out the recording here!

Top Solution Authors
Top Kudoed Authors
Users online (64,113)