Looks like you just need to make the combobox opaque. Set fillAlphas="[1,
1]" for Combo in checkBoxEditor.mxml.

-Jayant

On Sun, Apr 4, 2010 at 3:30 AM, Bala_V <[email protected]> wrote:

>
>
>
> Hi.
>
> Iam using a combo box as item editor and am rendering it dynamically using
> action script. My requirement is simple.
> a.) I have 3 values, Y, N and TBD. The default is TBD.
> b.) When I click on the drop down, the TBD is visible at the background of
> the drop down.
>
> Not sure why this is happening and because of this, the look and feel is
> not
> all that good.
>
> Request your help to get rid of this problem.
>
> main app
> -------------
> <?xml version="1.0" encoding="utf-8"?>
> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";
> layout="absolute" xmlns:stax="Stacks.*" height="100%" width="100%"
> xmlns:local="*">
> <mx:Script>
> <![CDATA[
> import mx.collections.ArrayCollection;
> [Bindable]
> public var dp:ArrayCollection = new
> ArrayCollection([
> {Category:"0",Risk:"Y"} ,{Category:"1",Risk:"Y"},{Category:"1",Risk:"N/
> A"}
> ]);
> ]]>
> </mx:Script>
> <mx:Panel label="Report" title="Report" height="100%" width="100%"
> styleName="Panel">
> <mx:AdvancedDataGrid width="200" height="200"
> id="dProvider1"
> dataProvider="{dp}"
> editable="true" borderThickness="2"
> headerHeight="40"
> headerWordWrap="true" wordWrap="true" >
> <mx:columns>
> <mx:AdvancedDataGridColumn
> dataField="Category"
> headerText="Deliverable
> Category" width="50" editable="false"/>
> <mx:AdvancedDataGridColumn dataField="Risk"
> headerText="Risk(RYG)"
> width="50" editorDataField="selectVal"
> itemEditor="checkBoxEditor"/>
> </mx:columns>
> </mx:AdvancedDataGrid>
> </mx:Panel>
> </mx:Application>
> checkBoxEditor.mxml (Item editor)
> ----------------------------
> <?xml version="1.0" encoding="utf-8"?>
> <mx:HBox xmlns:mx="http://www.adobe.com/2006/mxml";
> creationComplete="initMe()" >
> <mx:Script>
> <![CDATA[
> import mx.collections.ArrayCollection;
> [Bindable]
> public var selectVal:String = "";
> [Bindable]
> private var typeRisk:ArrayCollection = new
> ArrayCollection([{type:"TBD"},
>
> {type:"N/A"},{type:"Y"},{type:"G"} ]);
> private function initMe():void
> {
> selectVal = data.Risk;
> for (var i:int =0;i<typeRisk.length; i++) {
> if (typeRisk[i].type == data.Risk) {
> Combo.selectedIndex = i;
> }
> }
> }
> private function selectionChange():void
> {
> selectVal = Combo.selectedItem.type;
> }
> ]]>
> </mx:Script>
> <mx:ComboBox id="Combo" dataProvider="{typeRisk}" labelField="type"
> change="selectionChange()"/>
> </mx:HBox >
>
> Thanks
> Bala http://old.nabble.com/file/p28116393/issue.jpeg
> --
> View this message in context:
> http://old.nabble.com/Combobox-editor-problem-tp28116393p28116393.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
>
>  
>



-- 
main(){int
j,i=0;for(;i<54;++i%18==0?putchar(10):i)putchar((j="b`bxb]]0xxb]xb]b`b:QAabR^`wabRQ1Q;Q/bw>w2^<_...@w3^^=^?_"[i])<66?32:j+98);}

Reply via email to