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

RE: xrm weirdness?

$
0
0

Because you didn't consider the + operator

In fact the output of first alert is "false", not "is return/cancel = false"
this happens because the == operator is comparing the string "is return/cancel = Return/Cancellation" with the string "Return/Cancellation" and of course they are not equal and the output is false.

If you change the code to

alert('is return/cancel = ' + (selectedVal == 'Return/Cancellation'));

you will see the correct result


Viewing all articles
Browse latest Browse all 87499


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>