Hi all,
I am new to the Flash platform. My work is on Java. But, I need the help of a flash file(.swf) in my Java application to work with. So, I came to here to listen my doubts like this in this forum.
**Can we pass relative-url using ActionScript 3.0 with Flash?**
I have worked with absolute-url till now[WHICH IS IN BOLD] within localhost server only. And my sample piece of code looks like below:
var request:URLRequest = new URLRequest("http://localhost:8082/getviews");
var urlLoader:URLLoader = new URLLoader();
urlLoader.dataFormat = URLLoaderDataFormat.TEXT;
urlLoader.addEventListener(Event.COMPLETE, completeHandler1);
urlLoader.load(request);
function completeHandler1(event:Event):void {
trace(“ Inside COMPLETE handler.”);
var loader:URLLoader = URLLoader(event.target);
var listData:String=loader.data;
trace("listData: "+listData);
var viewswithusertype:Array=listData.split("$");
/* These are the fields saved in the database server.
* Further,I am trying to pass these fields using URLVariables
* class available in AS-3.0 into
*/
usertype=viewswithusertype[0];
var views:String=viewswithusertype[1];
var users:Array = views.split(".");
trace("list is:"+users.length);
for (var t=0; t<users.length; t++) {
trace("in for loop");
var itemname:String=users[t];
var itemslist:Array=itemname.split(",");
trace("itemslist : "+itemslist);
comboBox_mc.addItem({label:itemslist[1],data:itemslist[0]});
}//for
}//CompleteHandler1()
Can anyone post me with an example or a url regarding this problem.
I request you to please spend 2 minutes of your valuable time in replying to this post so that I can solve this issue.
Thanks in advance,…
Srihari.Ch