Hi,
I would like to display the total number of rows in Contacts subgrid on Account form. My code is:
function recordcount()
{
var TRC = Xrm.Page.getControl("accountcontactsgrid").getGrid().getTotalRecordCount();
Xrm.Page.getAttribute("eg_recordcount").setValue(TRC)
}
But I am getting error:
TypeError: Unable to get property 'getGrid' of undefined or null reference at recordcount
Can somebody help.
Br