The Tree control in Adobe Flex
The Tree control is much like the folder explorer feature of window. It helps us to explore the folders without moving inside to each folder, we can see the list of folders and files of each folder by clicking the folder icon.
Each folder is called node, it could be leaf (i.e. it does not contain any files or folders) or branch (i.e. it has files and folders).
In general hierarchical data provider, such as XML, provides the data. We should use ArrayCollection and XMLListCollection object if the data of the Tree is dynamic in nature.
DefaultDataDescriptor (Default descriptor data of tree to parse and manipulate data) class supports the following data types:
Flex Tree Component Example 1:ong>
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"><mx:Panel>
<mx:Tree labelField="@label" showRoot="true"> <mx:XMLListCollection> <mx:XMLList xmlns=""> <folder label="Message"> <folder label="create"/> <folder label="sent items"/> <folder label="inbox"/> <folder label="draft"/> <</folder> </mx:XMLList> </mx:XMLListCollection> </mx:Tree></mx:Panel>
</mx:Application>
Output:trong>

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.