Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

Editable subgrid data update on save

Posted on by 110

Hi

   I have an custom timesheet entity where I have a field "actual hours" which is updated by setting the difference in start and end time.I also have a decimal field "total " where it is calculated from actual hours.I also have another test entity where the data of timesheet enity are stored in an editable subgrid. I have done a script to calculate actual hours in the editable subgrid on change of start time and end time on the grid.  Actual hours is getting calculated in the grid record and the timesheet record .But "total " field is getting updated only on save of the form . So on update of data from editable subgrid, though the actual hours  is getting updated in the form, total is not getting updated. Any suggestions for updating total on change of actual hours from the grid.

*This post is locked for comments

  • Verified answer
    sathish1109 Profile Picture
    sathish1109 110 on at
    RE: Editable subgrid data update on save

    Hi,

       I ve achieved my requirement using a business rule with scope as "Entity". 

    Thanks  and regards,

    Sathish kumar S

  • sathish1109 Profile Picture
    sathish1109 110 on at
    RE: Editable subgrid data update on save

    Hi Neil Parkhurst,

       Your idea of adding total field to editable grid will help me solve the problem. But based on my requirement the view should not contain total field in the subgrid. Is there a chance that i can add the field to the grid and hide it from the view.?

  • Verified answer
    Neil Parkhurst Profile Picture
    Neil Parkhurst 10,725 User Group Leader on at
    RE: Editable subgrid data update on save

    When you say script, I assume you mean JavaScript that is being triggered by the editable grid.

    Have you included the total field in the editable grid? I suspect it might need to be included.

    If this doesn't solve you issue could you post a copy of your script. It might be that seeing your script will help provide an answer to your issue.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans