[英]dynamics crm get name of subgrid on associated view
When I open the contact form and then select activities from the navigation bar, the associated activities view appears. 当我打开联系表单,然后从导航栏中选择活动时,将出现关联的活动视图。 Is there a way to get the name of the subgrid for this view?
有没有办法为该视图获取子网格的名称? I
一世
var subgrid = Xrm.Page.getControl(<sub-grid name>);
Note: This is unsupported customization. 注意:这是不受支持的自定义。
Getting Associated view grid is different from subgrid in entity forms. 获取关联视图网格与实体表单中的子网格不同。 Subgrid in CRM form is accessible using
Xrm.Page.getControl(subgrid_name)
like any other control. 可以像其他任何控件一样,使用
Xrm.Page.getControl(subgrid_name)
访问CRM格式的Xrm.Page.getControl(subgrid_name)
。
But to access Associated view grid, you have to do DOM manipulation starting from IFRAME, then Grid like below. 但是要访问关联的视图网格,您必须从IFRAME开始进行DOM操作,然后再进行如下所示的Grid操作。
To get the IFrame control: 要获取IFrame控件,请执行以下操作:
var frame = document.frames[“areaActivitiesFrame”].frameElement;
To refresh the associated grid view: 要刷新关联的网格视图:
frame.contentWindow.document.getElementById(“crmGrid_Account_ActivityPointers”).control.refresh();
Once you get the control, try to override the click event like explained in SO thread 获得控件后,尝试覆盖SO事件中所述的click事件
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.