Is something wrong with subgrid?
-
Wednesday, April 06, 2011 6:52 AM
Hi,
I am currently using CRM 2011 and made a custom entity.
The entity has some subgrids on the form.
While some of the subgrids fields show data on their fields properly, others show link message
on their fields, which is "To load [EntityName] records, click here."
In this case, I must click the link in order to show data.
Does anyone know what makes this difference and how to avoid this problem?
(I am sorry to bother you if someone had already answered this question)
Many thanks,
Tomohiro Sakai
All Replies
-
Wednesday, April 06, 2011 10:52 AM
Is there any JScript running on the form that is updating any control's layout (probably in unsupported fashion). However, there is a workaround too to solve your problem
1. Know tab's name and subgrid's name from their properties
2. Call the refresh method on the subgrid like this Xrm.Page.ui.tabs.get('TabName').controls.get('Subgrid').refresh(). This will reload the faulting subgrid and get rid of the "To load.." message.
Manny Grewal || Australia- Proposed As Answer by Manny Grewal Wednesday, April 06, 2011 10:52 AM
-
Wednesday, June 08, 2011 6:10 AM
Hy
I've exactly the same issue here...I've no Jscript running on the form, do I really heave to call the refresh-method? What is causing this behaviour?
Kind regards,
Peter -
Friday, July 08, 2011 11:20 PM
Hi Sakai,
Did you find the answer for this issue, please let me know.
Thanks
RED
-
Friday, July 08, 2011 11:29 PM
Hi Tomohiro,
CRM only retrieves data for the first four subgrids without the user clicking on the link. This is to reduce the impact on the server at executing all of the subgrid queries at the same time. You can collapse tabs for those subgrids which you don't need right away.
Hope this helps,
Rich Dickinson
Program Manager - Dynamics CRM- Proposed As Answer by Phil Edry Tuesday, August 02, 2011 6:23 PM
-
Tuesday, February 28, 2012 9:48 AM
Hi Tomohiro,
CRM only retrieves data for the first four subgrids without the user clicking on the link. This is to reduce the impact on the server at executing all of the subgrid queries at the same time. You can collapse tabs for those subgrids which you don't need right away.
Hope this helps,
Rich Dickinson
Program Manager - Dynamics CRMYes, Tomohiro is right.
If you have more than 4 sub-grids in a form u have inserted, CRM will automatically load the 1st 4 sub-grids and for the rest sub-grid it will not load, rather it will give a link "To load <entityname> records, click here."
This is because CRM takes care of the efficiency of the form to be loaded faster.
if you want to load the grids after 4th grid, then get the object of the sub-grid and force it to load.
Xrm.Page.ui.tabs.get('<TabName>').controls.get('<Subgrid_Name>').refresh().
thanks,
yes.sudhanshu
yes.sudhanshu
http://bproud2banindian.blogspot.com
http://ms-crm-2011-beta.blogspot.com- Proposed As Answer by yes.sudhanshu Thursday, March 15, 2012 2:46 AM
-
Friday, June 08, 2012 11:13 AM
Hi,
Since the subgrid is inside a section, "Xrm.Page.ui.tabs.get('<TabName>').controls.get('<Subgrid_Name>').refresh()" throws null reference error.
So it should be
Xrm.Page.ui.tabs.get('<TabName>').sections.get('<SectionName>').controls.get('<Subgrid_Name>').refresh()