Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 87499

RE: CRM 2011 Odata/JSON Object

$
0
0

You can do just as you did before but check for the length of results. If the number is zero, you got a no go.

Depending on what action you attending to perform, you could also use the unindexed iterator.

for(var element in d.results){
  doYourMagic(element);
}

I haven't seen your code so it's a bit har to tell, but generally, if you wish to check if you got a nothing, you can use something like this.

if(myElement){
  alert("You got something");
} else {
  alert("No such thing!");
}

I'm assuming we're talking JavaScript, right?


Viewing all articles
Browse latest Browse all 87499

Trending Articles