PDA

View Full Version : whats wrong with this if/else?


YpsiloN
10-26-2003, 05:25 PM
- volta.txt: -
&algus=kinnis
&keel=est
&textloaded=OK


- flash: -
loadVariables("volta.txt", _root)
testasi = "kinnis";
if(algus == testasi){
algusline = "20"
} else {
algusline = "30"
}


so why I dont get 20 ever? I have tried like 'kinnis', "kinnis", kinnis and all but it always sets algusline to 30 and never to 20?? WHY? what I am doing wrong? if I put
testasi = algus;
and then if (algus == testasi) then I get 20... but never when I try to set testasi by myself...

cobo
10-28-2003, 05:59 AM
checked the pathes ?
is everything on _root ?

use some more semicolons ;)

- flash: -
loadVariables("volta.txt", _root);
testasi = "kinnis";
if(algus == testasi){
algusline = "20";
} else {
algusline = "30";
}

cobo

binkyboo
10-28-2003, 12:29 PM
Try this:

- volta.txt: -
&algus=kinnis&
&keel=est&
&textloaded=OK&