Hi,
I've got a combo box with labels that are very long... i created the combobox with the following script:
Code:
// combo box
this.createClassObject(mx.controls.ComboBox, "my_cb", 10);
my_cb.addItem({data:"/solutions/industry/aerospace/index.htm", label:"Aerospace and Defense"});
my_cb.addItem({data:"/solutions/industry/automotive/index.htm", label:"Automotive"});
my_cb.addItem({data:"/solutions/industry/consumer/index.htm", label:"Consumer Products"});
my_cb.addItem({data:"/solutions/industry/discrete_manufacturing/index.htm", label:"Discrete Manufacturing"});
my_cb.addItem({data:"/solutions/industry/finance/index.htm", label:"Financial Services"});
my_cb.addItem({data:"/solutions/industry/healthcare/index.htm", label:"Healthcare"});
// Position
my_cb._x = 40;
my_cb._y = 520;
// Parameters
my_cb.rowCount = 13;
my_cb.minWidth = 300;
// Create listener object.
var cbListener:Object = new Object();
// Create event handler function.
cbListener.change = function (evt_obj:Object) {
trace("Currently selected item is: " + evt_obj.target.selectedItem.label);
trace("Currently selected url is: " + evt_obj.target.selectedItem.data);
getURL( evt_obj.target.selectedItem.data, "_blank");
}
// Add event listener.
my_cb.addEventListener("change", cbListener);
i attempted my_cb._width = 300; , but this stretches the down button. is there any way to widen the text area so the whole label shows?
thanks!