parent
f7b841e21e
commit
3a160b9ea6
@ -0,0 +1,32 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
|
||||||
|
backgroundColor="#FFFFFF"
|
||||||
|
backgroundAlpha="0"
|
||||||
|
xmlns:custom="components.*">
|
||||||
|
|
||||||
|
<mx:Script>
|
||||||
|
<![CDATA[
|
||||||
|
import mx.controls.Alert;
|
||||||
|
|
||||||
|
private function showMonth():void{
|
||||||
|
Alert.show("Thank you " + fullname.text +
|
||||||
|
'! \nYour gift will arrive in ' +
|
||||||
|
month.selectedItem + '.');
|
||||||
|
}
|
||||||
|
]]>
|
||||||
|
</mx:Script>
|
||||||
|
|
||||||
|
<mx:Form>
|
||||||
|
<mx:FormHeading label="Get a free gift!" />
|
||||||
|
<mx:FormItem label="Name">
|
||||||
|
<mx:TextInput id="fullname" />
|
||||||
|
</mx:FormItem>
|
||||||
|
<mx:FormItem label="Select delivery month">
|
||||||
|
<custom:ComboBoxMonths id="month" />
|
||||||
|
</mx:FormItem>
|
||||||
|
<mx:FormItem>
|
||||||
|
<mx:Button label="Submit"
|
||||||
|
click="showMonth()" />
|
||||||
|
</mx:FormItem>
|
||||||
|
</mx:Form>
|
||||||
|
</mx:Application>
|
@ -0,0 +1,19 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<mx:ComboBox xmlns:mx="http://www.adobe.com/2006/mxml">
|
||||||
|
<mx:dataProvider>
|
||||||
|
<mx:ArrayCollection>
|
||||||
|
<mx:String>January</mx:String>
|
||||||
|
<mx:String>February</mx:String>
|
||||||
|
<mx:String>March</mx:String>
|
||||||
|
<mx:String>April</mx:String>
|
||||||
|
<mx:String>May</mx:String>
|
||||||
|
<mx:String>June</mx:String>
|
||||||
|
<mx:String>July</mx:String>
|
||||||
|
<mx:String>August</mx:String>
|
||||||
|
<mx:String>September</mx:String>
|
||||||
|
<mx:String>October</mx:String>
|
||||||
|
<mx:String>November</mx:String>
|
||||||
|
<mx:String>December</mx:String>
|
||||||
|
</mx:ArrayCollection>
|
||||||
|
</mx:dataProvider>
|
||||||
|
</mx:ComboBox>
|
Loading…
Reference in new issue