Home Tutorial Flex Flex4 Components VBox Container in Flex4

 
 

VBox Container in Flex4
Posted on: May 29, 2010 at 12:00 AM
The VBox container is a MX component. There is no Spark Component. The VBox container is used for vertical layout in which the children components are arrange vertically.

VBox container in Flex4:

The VBox container is a MX component. There is no Spark Component. The VBox container is used for vertical layout in which the children components are arrange vertically. You can use Spark Vertical layout instead of VBox Container.
The tag of VBox Container is <mx:VBox>.

Example:

<?xml version="1.0" encoding="utf-8"?>

<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"

xmlns:s="library://ns.adobe.com/flex/spark"

xmlns:mx="library://ns.adobe.com/flex/mx"

minWidth="955" minHeight="600">

<s:Panel title="VBox Container Example"

width="190" height="275"

contentBackgroundColor="#000000">

<mx:VBox borderStyle="solid"

paddingTop="10"

paddingBottom="10"

paddingLeft="10"

paddingRight="10"

x="21" y="20"

backgroundColor="#2F8F95"

cornerRadius="20"

borderAlpha="3"

borderColor="#250707"&>

<:TextInput id="txt" text="User Name" color="#ffffff" fontFamily="verdana"/>

<mx:Button id="btn" label="Button 1"/>

<mx:Button id="btn1" label="Button 2"/>

<mx:ComboBox id="comb"

prompt="Select Item"

color="#ffffff"

chromeColor="#000000"

cornerRadius="10"

direction="rtl"

symbolColor="#FFFFFF"

width="127"

fontFamily="verdana">

<mx:ArrayList>

<fx:String>Item 1</fx:String>

<fx:String>Item 2</fx:String>

<fx:String>Item 3</fx:String>

<fx:String>Item 4</fx:String>

</mx:ArrayList>

</mx:ComboBox>

</mx:VBox>

</s:Panel>

&</s:Application>

Output:

Running Application:

To view this page ensure that Adobe Flash Player version 10.0.0 or greater is installed.

Download this code

Related Tags for VBox Container in Flex4:


Ask Questions?

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.