Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

Show specific view in Sitemap

(1) ShareShare
ReportReport
Posted on by 30

I have used the below link to show specific view from the sitemap.

https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/open-forms-views-dialogs-reports-url#display-a-view-in-the-application-navigation-using-the-site-map

It all works good and show that view but other views also with view selector.

It further said in a note that "If you specify the view using the /main.aspx page, the view selector will still be shown. If the user changes the view, Model-driven apps remembers the user’s most recent selection and the initial default view displays after they close and re-open their browser."

If I remove "/main.aspx" from the URL "/main.aspx?pagetype=entitylist&etn=account&amp;viewid=%7b<GUID value of view id>%7d” and put only pagetype=entitylist&etn=account&amp;viewid=%7b<GUID value of view id>%7d then it does not show anything on left navigation in Sitemap.

My requirement is to show only that view there with no view selector. I have three more views which I need in my model-driven app.

Is it possible?

Categories:
  • imocean Profile Picture
    5 on at
    Show specific view in Sitemap
    Hi there,
    I can't see the code posted by Clofly Mao, can it be re-posted here please?
     
    Thanks a lot!
  • Suggested answer
    BernardV Profile Picture
    15 on at
    RE: Show specific view in Sitemap

    It helped me a lot. Thanks for posting this!

  • cloflyMao Profile Picture
    25,194 on at
    RE: Show specific view in Sitemap

    Hi deeprime,

    Please let me know whether the solution could make sense for you. :)

  • Verified answer
    cloflyMao Profile Picture
    25,194 on at
    RE: Show specific view in Sitemap

    Hi Deep Prime,

    View is part of main.aspx, so we shouldn't remove the "/main.aspx".

    Actually such of URL "/main.aspx?pagetype=entitylist&etn=account&amp;viewid={<GUID value of view id>}" can be regarded as a directive to show a specific view instead of a standalone page, we can see that if we change the view, only viewid parameter of the URL will change accordingly, and the view will be rendered to a different view.

    In a word, UCI is a single page application.

    You could refer to following workaround to only show one view and do not want to disable other views in an app.

    1. Create a HTML web resource.

    2. Put the code to the file content.

    
    
        
        
        View
        
    
    
    
    
        
    
        
    
        
    
        
    
    
    

    It create a copy of the whole page using iframe(a URL to show a specific view), then inject custom CSS rules to hide top and left navigation bar, and disable selector drop down menu.

    3. Change the sitemap item to this web resource.

    Test

    It looks similar to the URL method, but the source has been changed to web resource, and chevron symbol is hidden, now we can't select other views.

    8540.a1.JPG

    We can still click any of a record to open it in form, but the content will be loaded in the iframe. (It only works when we are selecting the sitemap item.)

    6607.a3.JPG

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

Dynamics 365 Community Update – Sep 16th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

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

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Jatinkumar Profile Picture

Jatinkumar 50

Featured topics

Product updates

Dynamics 365 release plans