Hi All,
I'm working off of something that someone else coded, and trying to
make it read some xml data (it was just reading a static include).
Anyway, it loops through 72 county nodes. I've got this part working:

//loop through and set all the county vars
var countyNodeLength = countyNodes.length;
for (var i = 0; i < countyNodeLength; i++) {
        thisCounty = countyNodes[i].firstChild.firstChild.nodeValue;
        thisLink = countyNodes[i].lastChild.firstChild.nodeValue
       // this line sets the vars - I couldn't get it to work
properly using the "var" keyword
        set (thisCounty + "_URL",  thisLink);
}

But, a litte later on, he had hardcoded the following stuff 72 times,
where Douglas is one example of a value that would be in the
"thisCounty" set in the loop above:

Douglas_color = new Color(_root.Douglas.btn_color);
Douglas_color.setRGB(out_color);

if (Douglas_URL == "undefined" || Douglas_URL == undefined) {
        Douglas._visible = false;
}

I haven't been able to figure out a way to set that dynamically as I
run through the loop. Is it even possible to do that much dynamic
evaluation?

Thanks in advance.
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to