web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Create a canvas app wi...
Power Apps
Answered

Create a canvas app with deep link to a specific screen using Containers and not Screens

(1) ShareShare
ReportReport
Posted on by 80

Hi All,

 

I am referring to the following link:

https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/how-to/deep-linking

 

One challenge I am observing having one screen vs multiple screens is the ability to use DeepLink using Params on the App StartScreen property. I am using containers to set visibility of my galleries and struggling to perform deepliking to a specific container from the StartScreen, any ideas are really appreciated.

 

Thanks,

Shalabh

Categories:
I have the same question (0)
  • Verified answer
    poweractivate Profile Picture
    11,078 Most Valuable Professional on at

    @ShalabhGupta 

    It seems you have a problem with using deep linking in Power Apps within a single screen setup using containers.


    I understand you may be trying to use the Param() Power Fx function to navigate directly to a specific container.

    While using multiple screens for different views can provide an easier way to deep link directly into the specific screen, it is also possible to manage it within a single screen using containers, though it is in a bit more complex way.

     

    Here's a method you can try instead:

    1. Define a global variable to store the context: You can try to use the Param() function in the OnStart property of the app to go ahead and read the deep link parameter and store it in a global variable. For example:

    If(Not(IsBlank(Param("containerId"))), Set(globalContainerId, Param("containerId")))


    2. Control visibility of each container: In the visible property of each container, you can try and use a comparison to the global variable globalContainerId to decide whether to show or hide the container. For instance:

    If(globalContainerId = "container1", true, false)


    3. Reset the global variable: After navigating to a container or making it visible based on the Param(), you may want to try and reset the globalContainerId to ensure that it doesn't interfere with the subsequent navigation attempts within the app.

     

    Remember also that your container ID should be unique and it's a good practice to follow a consistent and descriptive naming strategy so it is easy for you to maintain the app.

     

    Please be aware that although this method might work, it may have some limitations. For example, it might become complex to maintain this as the number of containers increase. Also, it relies on the logic in the app correctly setting and resetting the global variable.

     

    See if this helps as starting point @ShalabhGupta 

  • Shalabh Gupta Profile Picture
    80 on at

    Thanks for a quick response. I am using custom-control tabbed approach to show/hide containers by setting in some variables. Let me try this approach or a tweak to it to see if this works and get back to you. Appreciate your help.

  • Shalabh Gupta Profile Picture
    80 on at

    Hi,

     

    I am using a custom control (reusable) to setup tabs in my power apps as shown here:

    https://www.matthewdevaney.com/power-apps-tabbed-form-with-an-awesome-looking-design/

     

    With this approach, navigating between tabs I use the following approach to show the tab and container visible:

     

    1. OnVisible Property of the Tab control: varVisibleDashboard

    2. OnTabSelected property of the Tab control: varTabSelected

    3. OnSelect property of the tab control: 

                   UpdateContext({varTabSelected: Self.Text});

                   Set(varVisibleDataCallDetails,false);

    4. Dashboard Container: 

         OnVisible:  varTabSelectedDataCall = "Dashboard"

     

    ShalabhGupta_1-1685503737637.png

     

    ShalabhGupta_0-1685503718945.png

     

    So I guess I have to use update-context to set the active-tab's value and unable to do so on the App.OnStart.

  • iso Profile Picture
    250 on at

    @ShalabhGupta Also make sure that in the OnStart property of the App, you insert before this line 

    If(Not(IsBlank(Param("containerId"))), Set(globalContainerId, Param("containerId")))

     

    the following code:

     Set(globalContainerId, Blank());

    The reason is because if the condition

    If(Not(IsBlank(Param("containerId")))

    is not true, then the global variable globalContainerId is never set and this will cause problems later if you have other If() statements testing globalContainerId .  For some reason, if it is never set, so does not exist, the app does not generate an error if you test If(globalContainerId=...) .  Just happened to me right now.

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 335 Most Valuable Professional

#2
11manish Profile Picture

11manish 165

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 96 Super User 2026 Season 1

Last 30 days Overall leaderboard