Código :
<?xml version="1.0" encoding="utf-8"?>
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:miclase="services.miclase.*"
xmlns:empleadoservice="services.empleadoservice.*"
xmlns:miclase1="services.miclase1.*" title="registros" creationComplete="onInit();">
<fx:Script>
<![CDATA[
import mx.collections.ArrayCollection;
import mx.events.FlexEvent;
import mx.rpc.events.ResultEvent;
[Bindable]
public var categoryArray:ArrayCollection;
protected function Back(event:MouseEvent):void
{
navigator.popView();
}
private function onInit():void{
Servicio.getusuarios.send();
}
public function onResult(e:ResultEvent):void{
categoryArray = new ArrayCollection(e.result as Array);
//categoryArray=e.result.data;
}
protected function Cargar(event:MouseEvent):void
{
Servicio.getusuarios.send();
}
]]>
</fx:Script>
<fx:Declarations>
<s:RemoteObject id="Servicio" endpoint="http://172.16.2.237/practicanteunab/amfphp/gateway.php" source="Ejemplo.miclase" destination="Ejemplo.miclase" showBusyCursor="true">
<s:method name="getusuarios" result="onResult(event);" >
</s:method>
</s:RemoteObject>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<s:titleContent>
<s:Button label="Back" click="Back(event)"/>
</s:titleContent>
<s:Button x="219" y="158" label="Cargar" click="Cargar(event)"/>
<s:List x="78" y="109" dataProvider="{categoryArray}"> </s:List>
<fx:Declarations>
</fx:Declarations>
</s:View>
No imprime nada
