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 365 | Integration, Dataverse...
Unanswered

Show/Hide public views based on team (or role) (RetrieveMultiple plugin applied to SavedQuery) - not working...

(1) ShareShare
ReportReport
Posted on by 30

Hi,

I'm trying to write a RetrieveMultiple plugin to show/hide entity views, based on a user's team (alternatively, based on role would also be acceptable).

I've tried to adapt the code made available here:
https://prasannavadlamudiblog.wordpress.com/2018/06/09/team-based-views-in-microsoft-dynamics-crm-365/

I've amended that code to cater for the fact that UCI renders views using FetchExpression, and not QueryExpression.

The code doesn't seem to work, however. I have debugged and can't see any problems, so I'm very confused why this isn't working.

I was hoping that someone might be kind enough to help me with understanding why this doesn't work?

Here is my code (I wasn't able to paste in this post--I think it's too long):
https://pastebin.com/QMmA7XtL

And here is my XML (which is used as an unsecured config to determine the target entity, the team name, and the views to show/hide):


 
  
   
   
  
  
 

If anyone can provide any assistance, I'd be very grateful!

Thanks

I have the same question (0)
  • vanfog Profile Picture
    30 on at
    RE: Show/Hide public views based on team (or role) (RetrieveMultiple plugin applied to SavedQuery) - not working...

    Bump… anyone?

    I viewed the trace log and it doesn’t seem to be firing correctly when I view a table for a relevant entity. 

    The few times it does fire, all the trace events get called  

    Debugging and attaching to VS shows no issues. I’m at a loss as to what the issue could be.

    Any help or even a pointer in the right direction would be hugely appreciated!

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…

Andrés Arias – Community Spotlight

We are honored to recognize Andrés Arias as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
Sahan Hasitha Profile Picture

Sahan Hasitha 225

#2
DAnny3211 Profile Picture

DAnny3211 134

#3
Abhilash Warrier Profile Picture

Abhilash Warrier 129 Super User 2025 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans