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

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Portal: How to create Role Based Menu Items ?

(0) ShareShare
ReportReport
Posted on by 414

Hello everyone,

I want to create a dynamic navigation menu on my CRM Portal and there are some sublinks that I want to show only if the user has a certain web role, the parent link will be always visible.

Can anyone help me achive such thing?

Many thanks in advance,

Irena.

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at
    RE: How to create Role Based Menu Items ?

    Hi Ira,

    You can implement this by creating custom entity and XRMToolBox sitemapeditor. When you login to XRMToolBox sitemap editor you can find all of your navigation. You just need to add additional privileges for for each navigation which you want to control with role.

    Let say you have created one custom entity called "A"  , now in your sitemap editor find the "Navigation1" add one privileges with entity name "A" , providing "read"access (You may add any access like append, append to , write ,read)  for display and another navigation2 you add a privileges of access "Write" for display.

    Now create a security role and provide the privileges of the entity "A" based on definition of your sitemap. Once you assigned the security role to the user , then if the security role having entity "Read" access can see the "Navigation1". If the security role does not contain write access then the user will not see the "Navigation2".

    Hope this helps.

  • Irena Benja Profile Picture
    414 on at
    RE: Portal: How to create Role Based Menu Items ?

    Hello Goutam,

    Thanks for your response, but I do not want to change the CRM Navigation menu but the CRM Potral Navigation menu.

  • Suggested answer
    Rawish Kumar Profile Picture
    13,758 on at
    RE: Portal: How to create Role Based Menu Items ?

    Hi Ira,

    you have to create a new "web page access control rule" and select the required webpage , website , type of restriction.

    on the same form below or navigation from the record - you will see "web roles" add the required roles which should see or should not be able to see that page.

    docs.microsoft.com/.../webpage-access-control

    hope this helps

  • - Matt Bayes - Profile Picture
    890 on at
    RE: Portal: How to create Role Based Menu Items ?

    Hi Ira,

    To change the navigation in the portal you will have to utilize Web Page Access Control Rules. This can be found inside CRM under the Portals area.

    You will have to create a control rule for each page or sublink you would like to hide. Once you create the control rule and link it to the webpage, you can set the "Right" as Restrict Read. This will restrict read access to the page for the associated roles. Once the rule is created you can apply web roles via the sub-grid on the form. Essentially, any user that has the web role assigned to the Web Page Access Control Rule will be able to see the page.

    Hopefully this makes sense and solves your issue!

    - Matt -

  • Irena Benja Profile Picture
    414 on at
    RE: Portal: How to create Role Based Menu Items ?

    Hello,

    Thanks for the response!

    I have created the web page access control rule but is not affecting as should and my sublinks are always visible no matter the logged user role.

  • gdas Profile Picture
    50,091 Moderator on at
    RE: Portal: How to create Role Based Menu Items ?

    Hi Ira,

    Please ignore my suggestion as I assumed it was for Dynamics 365 UI.

  • - Matt Bayes - Profile Picture
    890 on at
    RE: Portal: How to create Role Based Menu Items ?

    Ira,

    I have found that setting up the Web Page Access Control Rules may required a clear of the cache, or even a restart of the portal. For some reason the rules don't get pulled to the portal right away. A restart should bring them in.

    Unfortunately it's just a "keep trying" sort of scenario.

  • Suggested answer
    Justinjose Profile Picture
    2,707 on at
    RE: Portal: How to create Role Based Menu Items ?

    Hi Ira B,

    You can achieve this through Web page access control rules, for example 

    Parent Link is Customer and two child link, Customer Contacts and Customer Account. Assign Restricted Read Rights to child , then add web role to show links based on role. Also add web roles for the contact.

    Content.png

    Thanks

    Justin Jose

  • Verified answer
    Community Member Profile Picture
    on at
    RE: Portal: How to create Role Based Menu Items ?

    It's not possible to hide child links using web access control rules. I suggest you use JavaScript for this. i have implamented this and it works fine for my portal.

    Refer this:

    arpitmscrmhunt.blogspot.sg/.../remove-forums-link-from-crm-portal-main.html

  • Suggested answer
    Justinjose Profile Picture
    2,707 on at
    RE: Portal: How to create Role Based Menu Items ?

    Hi,

    I think it's possible to hide child links using web access control rules with proper web roles. It worked for me. The above blog is saying "few links available on the portal that you cannot hide/show using access rules due to its own limitation. Forum link is one of them." I did try on all links. See below images which are from taken my demo environment. 

    Hide-Child-links.png

    Thanks

    Justin Jose

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
HR-09070029-0 Profile Picture

HR-09070029-0 2

#2
ED-30091530-0 Profile Picture

ED-30091530-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans