RE: WebApi retrieveMultipleRecords - how to process GUID
Sorry, I thought I had included enough detail. My WebApi call is this:
Xrm.WebApi.online.retrieveMultipleRecords("new_application", "?$select=new_term,new_nbr,new_decision,new_reply,new_applicationid&$filter=statecode eq 0 and new_term eq '"+term+"'").then(
function success(results) {
for (var i = 0; i < results.entities.length; i++) {
var url = "<a href='"+ clientUrl + results.entities[i]["new_applicationid"] +"' target='new'>" + results.entities[i]["new_nbr"] + "</a>";
var term = results.entities[i]["new_term"];
var course = results.entities[i]["new_name"];
var decision = results.entities[i]["new_decision@OData.Community.Display.V1.FormattedValue"];
var reply = results.entities[i]["new_reply@OData.Community.Display.V1.FormattedValue"];
}
},
function(error) {
Xrm.Utility.alertDialog(error.message);
}
);
All my attributes are being saved to the variables with the exception of the GUID, new_applicationid: results.entities[i]["new_applicationid"] is undefined when checked. The GUID does appear correctly in the results when the query is run on a browser. So my question is do I need to handle a GUID passed from the results differently to how I handle a string or an option set?