-
Code:
onClipEvent (enterFrame){
value = substring(this.myInput, 1, 4);
trace ("value: "+ value);
}
and
Code:
onClipEvent (enterFrame){
value = substring(this.myInput, 0, 4);
trace ("value: "+ value);
}
are the same? I got the same result for both codes.
please note the different: 1 and 0
-
Is this just alternative syntax?
I thought it was
value = this.myInput.substring(0,4);
What are you getting?
-
The only thing different in this 2 codes in index number, one is 1 and one is 0, but both produce the same result.
If my string is 123456, they both return: 1234and that's what got me confused.