Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>As the error states the method get_allRecordIds is not supported for that particular control. I would guess that Microsoft MAY have changed the structure of the HTML meaning that its not looking at the correct control. </p> <p>I'd suggest you use this instead</p> <pre><code>Xrm.Page.ui.controls.get('TimeTickets')._control.get_innerControl().get_allRecordIds(); </code></pre> <p>EDIT As mentioned by anykey3 this solution doesn't appear to work all the time either. I have it working on CRM Online however CRM on premise doesn't seem to work correctly. One solution I have that works is using the RESTful service which might not be the best solution as it requires ALOT more code.</p> <pre><code> function GetChildrenValues() { if (Xrm.Page.data.entity.getId() != null) { var odataFieldName = "ContactSet"; var identifier = new Array(); identifier[0] = Xrm.Page.data.entity.getId(); var context = Xrm.Page.context; var serverUrl = context.getServerUrl(); var ODATA_ENDPOINT = "/XRMServices/2011/OrganizationData.svc"; var odataUri = serverUrl + ODATA_ENDPOINT + "/" + odataSetName + '?$filter=accountid eq {GUID}'; odataUri += '?$filter=accountid eq {GUID}'; $.ajax({ type: "GET", contentType: "application/json; charset=utf-8", datatype: "json", url: odataUri, beforeSend: function (XMLHttpRequest) { //Specifying this header ensures that the results will be returned as JSON. XMLHttpRequest.setRequestHeader("Accept", "application/json"); }, success: function (data, textStatus, XmlHttpRequest) { SuccessCallback(data, textStatus, XmlHttpRequest); }, error: function (XmlHttpRequest, textStatus, errorThrown) { // Handle Error } }); } } function SuccessCallback(data, textStatus, XmlHttpRequest) { if (data.length &gt; 0) { var total = 0; for (var i = 0; i &lt; data.length; i++) { // Do something } } } </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload