:: Forum >>
data in js file
I would like to store the data for a combobox (dropdown) in a js file and use a function to load the dropdown
for instance in the js would be:
function alist(){
list = ["Home", "Favorites", "Font size", "Search"];
return list;
}
The main page would have;
var mylist = alist()
var sState1 = new AW.UI.Combo;
sState1.setId("sState1");
sState1.setItemText(mylist);
sState1.setItemCount(4);
sState1.refresh();
I can't seem to get the list loaded using a function. I've tried variations of this. Can it be done?
ira berkowitz
Thursday, February 22, 2007
Yes, it should work like this. Maybe there are some syntax errors (like missing var declaration or missing semicolon)?
Alex (ActiveWidgets)
Thursday, February 22, 2007
This topic is archived.
Back to support forum
Forum search