Refresh form automaticaly when a new record is added to a subgrid RRS feed

  • Question

  • Hello Everybody,


    I have a small problem and was wonderign if somebody can help me. I have a subgrid in crm2011 form. 

    When I add a new record to the subgrid i wanted to count the number of records in subgrid and display on the mainform header. But unless the refresh the form manually, the count doesn't seem to change after i make any changes to existing or add a new record to the subgrid.


    I wanted to do this in javascript. can someone suggest me .Any guidance is much appreciated.


    Thanks in Advance.

    Wednesday, July 6, 2011 3:27 PM

All replies

  • http://joegilldotcom.blogspot.com/2011/06/crm-2011-how-to-refresh-form-after.html


    but you can also add index line and you will see the record count for subgrid elements

    Carsten Groth http://carstengroth.wordpress.com
    Wednesday, July 6, 2011 6:09 PM
  • Hi,

    Below code is to find the IFrame count records in 4.0 on onload Javascript. You can convert it for CRM 2011 for subgrid.

    var frameDoc = document.getElementById('IFrame_contacts').contentWindow.document; 
    var recordcount = frameDoc.getElementById("crmGrid").InnerGrid.SelectedRecords.length;



    Thursday, July 7, 2011 6:16 AM