# Form arrays dont work plz help

**URL:** <https://forum.kirupa.com/t/form-arrays-dont-work-plz-help/71288>\
**Category:** Uncategorized\
**Created:** [November 23, 2004, 4:17am UTC](https://forum.kirupa.com/t/form-arrays-dont-work-plz-help/71288 "2004-11-23T04:17:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![olm75](https://avatars.discourse-cdn.com/v4/letter/o/8c91f0/32.png) [@olm75](https://forum.kirupa.com/u/olm75)\
**Post date:** [November 23, 2004, 4:17am UTC](https://forum.kirupa.com/t/form-arrays-dont-work-plz-help/71288/1 "2004-11-23T04:17:19Z")

</div>

for some reason my arrays dont work so when u choose a state the city combo box should populate the city of that state…but i just have bs in there for the cities now…here is script

florida= new Array(“Chrysler”,“Porche”,“Mazda”,“Toyota”);  
georgia = new Array(“Hamburger”,“Hotdog”,“Pizza”);  
alabama = new Array(“Water”,“Beer”,“Wine”,“Martini”);  
function setSubCombo() {  
city.removeAll();  
var subArray = eval(state.getSelectedItem().data);  
for(var i=0; i\<subArray.length; i++) {  
city.addItem(subArray\*,subArray\*);  
}  
}

// 6. Push Buttons  
// ---------------  
// Reset button function  
onReset = function () {  
// combobox  
state.setScrollPosition(0);  
state.setSelectedIndices(null);  
// combobox  
city.setScrollPosition(0);  
city.setSelectedIndices(null);  
// combobox  
venue.setScrollPosition(0);  
venue.setSelectedIndices(null);  
// combobox  
agegroup.setScrollPosition(0);  
agegroup.setSelectedIndices(null);  
// combobox  
musictype.setScrollPosition(0);  
musictype.setSelectedIndices(null);  
// text  
comment.text = “”;  
bar.\_visible = false;  
}  
// Submit button function  
onSubmit = function () {  
texte = comment.text;  
\_root.gotoAndStop (“1”);  
}
