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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Answered

Business rule not working for editable subgrid

(0) ShareShare
ReportReport
Posted on by 595

Hi, I'm using business rule to lock and unlock subgrid field, if field contains data then unlock field else lock field... but it is not working now? what might be the issue..... please suggest me... 

I have the same question (0)
  • Suggested answer
    meelamri Profile Picture
    13,216 User Group Leader on at

    Hi, 

    You need to use some JS code for this scenario.  Please check this thread: 

    https://stackoverflow.com/questions/57687304/disable-column-in-dynamics-crm-editable-subgrid-based-on-a-condition

  • Suggested answer
    protc Profile Picture
    on at

    Hi Abhilash,

    Thank you for your query.

    There are three options possible for the scope of a business rule;

    Single Form Scope – Use this when a business rule specifically applies to a single form. It involves selecting a specific form name.

    All Forms – Use this to apply the business rule to all forms. (Including main and quick create forms.)

    Entity – Use this to run the business rule at a form and server level. (Server level being triggered by a create or update of data.) Useful if the rule is to be applied not only on forms but when data is imported. Also useful if the business rule is to be applied to editable grids.

    pastedimage1593688084408v1.png

    Please make sure the Scope of the Rule is set to Entity.

    pastedimage1593688098577v2.png

  • Abhilash M abi Profile Picture
    595 on at

    i make scope as entity only but it is not working for editable grid... in form level it is working fine...

  • Suggested answer
    protc Profile Picture
    on at

    Hi Abhilash,

    In this case you can use the JS code to manipulate the fields as required,

    stackoverflow.com/.../disable-column-in-dynamics-crm-editable-subgrid-based-on-a-condition

  • Verified answer
    Bipin D365 Profile Picture
    28,983 Moderator on at

    Hi,

    Please see below blog which has js code to achieve your requirement.

    xrmdynamicscrm.wordpress.com/.../

    Pass the list of fields to be disabled in array object and attach the code on onrecordselect event.

    If found helpful, Please mark my answer verified.

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

News and Announcements

Season of Giving Solutions is Here!

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 365 | Integration, Dataverse, and general topics

#1
iampranjal Profile Picture

iampranjal 67

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 37 Super User 2025 Season 2

#3
Pallavi Phade Profile Picture

Pallavi Phade 24

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans