views:

29

answers:

3

I have searched a lot but could found a code where i can add comobox on screen CAn anyone give me example . like

Var combobox = new Combobox();

i don't have any gui

Where can i get the list/attributes of all the components like API for use in AS3

A: 

http://members.cox.net/midian/tutorials/combobox.htm

Try this link...Hope it helps you.

Jerry
thanks buddy but what is this mx , i am coding the as file nor mxml file.or i can use that syntax inside the .as file
Mirage
A: 

You're not being very clear with the question. If you want to add a ComboBox to the screen in AS3, your code works, except you need to attach it to something. e.g.,

var c:ComboBox = new ComboBox();
c.dataProvider = yourData;
someCanvas.addChild(c);

However, if you want to build your own ComboBox and have it pop up in a similar way, you're treading into more complicated land. The basics are that it's just a TextInput control where you use the PopupManager to show/hide a List object depending on the user action (e.g., click, typing, etc...). But you will run into lots of focus/event issues.

Take a look at the ComboBox source code in the Flex SDK.

Glenn