I'm missing something obvious. I've created the following object to be used as an item Editor. I want to make sure a number in the 1*10^-3 format is entered (the -3 can vary from -1 to -10) I am using this item editor in a datagrid. Whenever I activate the combobox it shows the data field and not the label as I expected. Any suggestions.
<?xml version="1.0" encoding="utf-8"?> <mx:ComboBox xmlns:mx="http://www.adobe.com/2006/mxml"> <mx:Script> <![CDATA[ override public function set data(obj:Object):void { } override public function get data():Object { if (this.selectedItem == null) { return null; } else { return this.selectedItem.data; } } ]]> </mx:Script> <mx:dataProvider> <mx:ArrayCollection> <mx:Object label="1E-1" data="0.1"/> <mx:Object label="1E-2" data="0.01"/> <mx:Object label="1E-3" data="0.001"/> </mx:ArrayCollection> </mx:dataProvider> </mx:ComboBox> -- http://www.atlantageek.com ------------------------------------------------------------- To unsubscribe from this list, simply email the list with unsubscribe in the subject line For more info, see http://www.affug.com Archive @ http://www.mail-archive.com/discussion%40affug.com/ List hosted by http://www.fusionlink.com -------------------------------------------------------------
