• Narrow screen resolution
  • Wide screen resolution
  • Decrease font size
  • Default font size
  • Increase font size
Forum Post: RE: JavaScript to pull an attribute from Owning user.
Mittwoch, 31. August 2016

First - you should add field you want to use in query like following: req.open("GET", Xrm.Page.context.getClientUrl() + "/api/data/v8.0/teams?$select=teamid,name&$filter=contains(name, 'West')", true); and after in callback you can use it like: req.onreadystatechange = function () { if (this.readyState === 4) { req.onreadystatechange = null; if (this.status === 200) { var results = JSON.parse(this.response); for (var i = 0; i < results.value.length; i++) { var teamid = results.value[i]["teamid"]; var name = results.value[i]["name"]; //your code logic here } } else { alert(this.statusText); } } };

Original https://community.dynamics.com/crm/f/117/p/210351/553347#553347.

 

Deutsch      English