knowledgecenter-breadcrum

Knowledge Center

10 Oct, 2020

How to add or remove user from Access team template programmatically

Posted on 10 Oct, 2020 by Admin, Posted in Dynamics 365 Dynamics-365 Sales

How to add or remove user from Access team template programmatically Blogs

How to add or remove user from Access team template programmatically

Introduction

In Dynamics 365 Business Applications, the access team is used to share the records with other users with different level of access rights like Read, Write, Delete etc.

In this blog, we are going to see how we can add/remove users to/from access team. Also, we will see how we can retrieve the user of access teams programatically.

Before we go to the programming approach of access team. First, we will see how we can enable the access teams for entity and to enable the access team please follow below steps:

Enable Access Team

  1. Go to entity and enable the Access team as shown below:
    In Classic User Interface:

    In Unified User Interface:
  1. Go to Settings > Security > Access Team Template and Add the template with required permission.


    Here, in the drop-down all access team enabled entities are visible.
  1. After Adding “Access team template”, now we need to add sub-grid on required entity’s form as shown below:
    Classic User Interface:

    Unified User Interface:

    Now, we are good to go with programming part.

Programming

  1. Add user to access team using below code.
  1. Remove user from access team using below code.
  2. Get Access Team Template using below FetchXml.
  3. Get users those are already in access team using below code.

Comment

This is a Required Field

Loading

Recent Updates

Email Storage Made Easy: Dynamics 365 Space Saving Tips
Blogs
29 Feb, 2024

Email Storage Made Easy: Dynamics 365 Storage Saving Tips

Email Storage Made Easy: Dynamics 365 Storage Saving Tips Introduction Microsoft's latest feature allows you to migrate email descriptions from CRM…

READ MORE
Blogs
28 Feb, 2024

How to enable the enhanced email template editor in Dynamics 365?

How to enable the enhanced email template editor in Dynamics 365? To activate the Enhanced Email Template editor for your…

READ MORE
RCA for ARC Migration Issue
Blogs
28 Feb, 2024

Troubleshooting Convert Rules Import Issue: Entity 'workflow' with ID Does Not Exist error in D365

Troubleshooting Convert Rules Import Issue: Entity 'workflow' with ID Does Not Exist error in D365 Problem Statement We implemented D365 Customer…

READ MORE