简体   繁体   中英

Combobox's Dynamic event in flex

I am using flex when i was select combobox item i want to create new form for eg. when i select 1 it will appear one form when i select 2 it will appear two.so and so....

Put your Forms inside of a ViewStack container. You can then bind the ViewStack's selectedIndex to the selectedIndex of your ComboBox:

<mx:ComboBox id="comboBox" />

<mx:ViewStack selectedIndex="{comboBox.selectedIndex}">
    <mx:Form id="formA">
        ...
    </mx:Form>
    <mx:Form id="formB">
        ...
    </mx:Form>
</mx:ViewStack>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM