I haven't really used RemoteObject a lot yet, but I was wondering the 
same thing. I think you're having trouble adding the method object to 
the RemoteObject Class... I'm not so sure about that either. This is 
just to clarify your question to others. I think that the current 
solution provided by other guys, though intended to be helpful, fails 
to explain how you really convert that code to its AS3 equivalent.

If that is the case, then the real question I guess is... are the 
method objects added to the RemoteObject added as a array list?

The rest of the code is simple:


private var myService:RemoteObject = new RemoteObject();

private function initApp():void {

   myService.showBusyCursor = true;
   myService.source = "tutorials.HelloWorld";
   myService.destination = "amfphp";
   myService.addEventListener("fault", faultHandler);

   // ADD METHOD CODE CAN GO HERE...!

}


Hope it helps!

Hyder
www.GulfSpecials.com
www.AlamgirDesigns.com
alamgirdesigns.blogspot.com


--- In flexcoders@yahoogroups.com, "timgerr" <[EMAIL PROTECTED]> 
wrote:
>
> Hello all, hope you all are doing good.  I have a question on how to
> build the Flex RemoteObject method in action script.  I am having
> troubles doing this.  Here is my RemoteObject:
> 
>       <mx:RemoteObject id="myservice" fault="faultHandler(event)"
> showBusyCursor="true" source="tutorials.HelloWorld" 
destination="amfphp">
>         <mx:method name="sayHello" result="resultHandler(event)" />
>     </mx:RemoteObject>
> 
> 
> Can someone take the above code and do it in acitonscript?  It is 
not
> that I want someone to do my work, I am having a hard time finding
> data to do this.  Most examples are in Flash and for some reason 
they
> do not work right in Flex.  
> 
> Thanks for all the help,
> timgerr
>



Reply via email to