Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Entity mapping and plugin

(0) ShareShare
ReportReport
Posted on by 100

Hi All ,

I have following scenario:-

Lets say i have two entity  A  with look up A and entity B with look up B on it.

Entity A form has a subgird of entity B.  When we create entity B record from subgrid , we have a mapping in place which is copies the value of look up A (Entity A) to look up B (Entity B).

Now as per my functionality i am writing my plugin on create of entity B in which i am making the value of look up B to null in some conditions.

Plugin is working fine if we are  creating entity B record  from other than subgrid. But if we are creating entity B record from subgrid , the look up B value is not setting to null. It is setting as per entity mapping

Is there anyway i can make look up B value to null  in my plugin ?

*This post is locked for comments

  • Suggested answer
    Michel Gueli Profile Picture
    Michel Gueli 982 on at
    RE: Entity mapping and plugin

    Is your plugin being executed? When you add the record through the subgrid, the plugin is only executed after you press save. The mapping is something that is being executed when the forms opens.

  • RaviKashyap Profile Picture
    RaviKashyap 55,410 Moderator on at
    RE: Entity mapping and plugin

    Hi Vaibhav,

    Please also share the plugin code to see how you are setting it to null. Also I am assuming that you are creating a new record from subgrid and not associating an existing record?

  • Mahendar Pal Profile Picture
    Mahendar Pal 45,095 on at
    RE: Entity mapping and plugin

    Hi Vaibhav,

    Can you share details about your plugin registration steps and share your code here ?? I think you need to run your plugin on post create.

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,575 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,493 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans