开发者

How to get array from server to form,as form items in flex?

开发者 https://www.devze.com 2022-12-12 22:41 出处:网络
am sending one user object from java to flex using remote object,now i want to get each item from that array to display in text boxes...how can i do this ?

am sending one user object from java to flex using remote object,now i want to get each item from that array to display in text boxes...how can i do this ?

userInfo=event.result as Array;

    <mx:FormItem label="FirstName" fontWeight="bold" width="325" required="true">
        <mx:TextInput id="firstname" text="{userInfo.getItemAt开发者_运维问答(0)}" width="220"/>
    </mx:FormItem>

    <mx:FormItem label="LastName" fontWeight="bold" width="325" >
        <mx:TextInput id="lastname" text="{userInfo.getItemAt(1)}" width="220"/>
    </mx:FormItem>

    <mx:FormItem label="Address" fontWeight="bold" width="325" >
        <mx:TextArea  id="address" text="{userInfo.getItemAt(2)}"  >
    </mx:FormItem>  

...i want something like this...Please help me any one


Try (userInfo[0] as String).

  • Check if userInfo isn't null.

(with Charles you could check if the userInfo is sent correctly with http).

0

精彩评论

暂无评论...
验证码 换一张
取 消