Says here:
http://www.openbluedragon.org/manual/?/cfscript
That I can loop over a struct and an array with Open bd (currently
running openbd on gae) however i get this when I attempt to do so:
"Only structs may be used in a for...in."
// Looping over a collection/struct
myStruct = {
name : "alan",
location : "scotland"
};
for ( key in myStruct ){
WriteOutput( myStruct[key] );
}
// Looping over an array
myArray = ["alan","andy","ceri"];
for ( arrElement in myArray ){
WriteOutput( arrElement );
}
I think the Array Syntax in general is not working - but neither does
this for looping:
// Looping over an array
myArray = ArrayNew(1); // simple empty array declared.
for ( arrElement in myArray ){
WriteOutput( arrElement );
}
Maybe this is just b/c I am not in the know with the versions...
kp
--
official tag/function reference: http://openbd.org/manual/
mailing list - http://groups.google.com/group/openbd?hl=en