Expand my Community achievements bar.

Radically easy to access on brand approved content for distribution and omnichannel performant delivery. AEM Assets Content Hub and Dynamic Media with OpenAPI capabilities is now GA.

call a remote object in custom preloader class

Avatar

Level 1
Hi All,



I am new to flex. i am trying to call a remote object in

custom preloader class.. is it possible to call a "remote
object"

inside custom preloader class?. and is it compulsory to write
remoteobject inside <mx:Application> tag only?



can anyone explain me how to call remote object in custom

preloader class.



Here is my code



<mx:Application preloader="###.###.Preloader">



public class Preloader extends DownloadProgressBar

{

public function Preloader()

{

super();

init();

}



private function initVars():void {

myRemoteObject = new RemoteObject();

myRemoteObject.destination = "searchService";



myRemoteObject.addEventListener(ResultEvent.RESULT,
resultHandler);



myRemoteObject.addEventListener(FaultEvent.FAULT,
faultHandler);

myRemoteObject.getPreferences("123");

}



}



thanks

uday
0 Replies