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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Make a contact not editable

(0) ShareShare
ReportReport
Posted on by

Hi All,

My company configured a generic Contact used as Default when  a specific field during company setup cannot be specified at the creation.

Now we are experiencing problems where people edit this generic contact instead of creating a new one once the person to be configured in the field above have been specify at business level.

I have been asked if Is possible to lock this generic contact so that nobody can edit it. I have google it for a while but cannot fine any answer for this. I have been able to find staff about security field level but it looks that configuring that will do it for all contact why I need this on a single contact.

Is this something feasible?

Thanks

Regards

Federico

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Kumar Viju Profile Picture
    1,026 on at

    Hi,

    The quickest way is use a JavaScript. Create a On Load Function and Check for Some Keyword. Ex:

    If ( Contact Name = "XYZ")

    {

     Disable All Fields on the Form

    }

    Refer:

    community.dynamics.com/.../189988

    stackoverflow.com/.../disabling-all-fields-on-a-form-in-crm-2015

  • Verified answer
    TheMarkChristie Profile Picture
    10,328 Moderator on at

    Hi

    You could make a business rule to say that if "Contact Name" = Generic User 123

    Set Fields (All on form) to Locked

  • Suggested answer
    Drew Poggemann Profile Picture
    4 on at

    The other options above are logical and will help to disable fields on a form but I would suggest to create a custom entity for this type of information and do not allow anyone to modify that entity.  You can then relate this to to customer or pull information from this entity on to the customer when it is created as default data.  

    Thanks much,  

  • Verified answer
    Tim Dutcher Profile Picture
    2,100 on at

    I've also worked on CRM systems where it was necessary to protect a fixed record. For example, a client had an account named "UNASSIGNED" and they related unknown contacts to that account. They did not want anyone to change anything about that fixed account record.

    If you only protect the record using client-side code then it's still possible for someone to update the record during a bulk update, Excel-based update, etc.

    If you also want to protect the record server-side, then you can create a simple plug-in. Sample code is below:

    // Register the plug-in on update of contact, pre-operation, synchronous.
    // Register a pre-image that gives you "fullname".

    Entity preImageEntity = (Entity)context.PreEntityImages["YOUR_PREIMAGE_NAME_HERE"];
    if (preImageEntity.GetAttributeValue<string>("fullname") == "YOUR_FIXED_CONTACT_NAME_HERE")
    {
       throw new InvalidPluginExecutionException("This contact cannot be modified.");
    }
     

  • ScottDurow Profile Picture
    21 on at

    Perhaps rather than use a plugin -you could simply create an sync workflow that tests for the name of the contact and then uses the stop with error to display the message to the user.

  • Tim Dutcher Profile Picture
    2,100 on at

    That would be too quick and easy, Scott.  :)

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
JS-09031509-0 Profile Picture

JS-09031509-0 3

#2
AS-17030037-0 Profile Picture

AS-17030037-0 2

#2
Mark Eckert Profile Picture

Mark Eckert 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans