I understand event.rc should have a default value of "true". However when I check the value in the debugger, it returns false.
Please consider this code ......
if(!event.willCommit) {
var vsChar = event.change;
switch (event.rc) {
case (vsChar.search(/[^a-zA-Z]+/) === -1):
event.change = event.change.toUpperCase();
break;
So the debugger steps in to the switch statement and evaluates the case properly (if event.rc was false this wouldn't have happened) but the debugger continues to return false as the value.
Even when I modify the code with
if(!event.willCommit)
{
event.rc = true;
var vsChar = event.change;
switch (event.rc)
{
case (vsChar.search(/[^a-zA-Z]+/) === -1):
{
event.change = event.change.toUpperCase();
break;
}
}
}
the compiler still manages to show false as the value? Is this correct?
FYI, I do clear out the console content of the debugger before I start running code
Thanks for your interest.
Paul