Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

How to prevent deleting record which are specified in Lookup

(0) ShareShare
ReportReport
Posted on by 545

How Can we stop deleting record which are specified in Lookup, is it can be achieved through out of the box feature or should write plug-in or custom workflow?

*This post is locked for comments

  • Verified answer
    Rawish Kumar Profile Picture
    Rawish Kumar 13,756 on at
    RE: How to prevent deleting record which are specified in Lookup

    Hi,

    you can stop a user from deleting a record if it being used in another lookup using out of the box relationship behavior.

    use cascading behavior and set restrict delete to All.

    refer to the cascading behaviour given here :

    msdn.microsoft.com/.../gg309412.aspx

    if you need to do on some condition then obviously you will have to write a plugin.

  • Verified answer
    gdas Profile Picture
    gdas 50,085 on at
    RE: How to prevent deleting record which are specified in Lookup

    Yes if you want to delete based on some condition then you can write plugin or  configure work flow .

  • Verified answer
    gdas Profile Picture
    gdas 50,085 on at
    RE: How to prevent deleting record which are specified in Lookup

    Hi Ganesh,

    Lookup records also belongs to entity so  you can achieve this using security role . Try to remove entity delete privileges of the assigned user security role.

    Hope this helps.

  • Verified answer
    Shahbaaz Ansari Profile Picture
    Shahbaaz Ansari 6,203 on at
    RE: How to prevent deleting record which are specified in Lookup

    Hi ganesh,

    You can write Plugin code for it, Please check below article how to write plugin on delete

    community.dynamics.com/.../write-a-common-plugin-for-create-update-delete-events-in-dynamics-crm-2011

    If you find it helpful, Please mark my Answer as Verified.

    Best Regards,

    Shahbaaz

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

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,711 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,458 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans