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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How might you record lock an entity instance based on a particular state.

(0) ShareShare
ReportReport
Posted on by 330

How might I, for example, lock a particular account record based on its status from another field in account - such that either i can't delete it or update it. Yet its still active?

Thanks

Stuart

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Mahendar Pal Profile Picture
    45,095 on at

    Hi,

    You can control it though code, you can have pre update and pre delete workflow/plugin which can validate your required, and can throw error which will cancel update/delete operation, so it won't let anyone update/delete account record.

  • Suggested answer
    Kokulan Profile Picture
    18,054 on at

    You can have a plugin that prevents deletion or update based on status or any field value - This prevents the update or delete at the server level.

    And then if you want to have the fields to be read only on the form, you will have to have a script / business rule to lock all the fields.

  • JackAll Profile Picture
    330 on at

    Thanks, Yes a plugin would be one way.

    Howevers is there not a feature within vanilla Dynamics that offers this protection?

    When an entity is inactive then it can't be updated - that's part of the way there.

    I'm assuming the business rule would be the better way if it can do everything.

    Perhaps mixed with user level security so you can only delete your own items, and then only if they are not at a certain state.

  • Suggested answer
    RaviKashyap Profile Picture
    55,410 Moderator on at

    Hi,

    Depends upon requirement, if you requirement is "can only delete your own items" then security role is the best. Otherwise you can surely write BR based on your custom business requirement.

    Hope this helps.

  • Verified answer
    gdas Profile Picture
    50,091 Moderator on at

    In addition you can also create workflow -

    Have a look below article

    nakedcrm.wordpress.com/.../using-workflows-to-validate-records-to-prevent-creates-updatesassign-and-deletes

    To see the UI field lock business rule is the best options..

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…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans