mxml日期显示使用

时间:2021-05-17 04:53:50
mxml代码:
<?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="" minHeight="">
<fx:Script>
<![CDATA[
import mx.collections.ArrayCollection;
import mx.controls.Alert;
public var arr:ArrayCollection = new ArrayCollection([
{label:"Dan Orlando"},
{label:"Tarip Ahmeh"},
{label:"John C Bland IT"}
]); ]]>
</fx:Script>
<fx:Declarations>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<mx:List id="myFriends" dataProvider="{arr}"/>
</s:Application> User类:
package com.xyw.model
{
public class User
{
public var id:Number;
public var username:String;
public var birthday:Date;
public function User()
{
}
}
}