import flash.display.LoaderInfo;
try {
var allFlashVars:Object = LoaderInfo(this.root.loaderInfo).parameters;
img_path = String(allFlashVars["path"]);
if (img_path.toString() == String(undefined)){
throw new Error("FlashVars did not load");
}
}catch(e:Error){
//error_txt.text = "did not load flash vars";
img_path = "path_to_my_image.jpg";
}
0 comments:
Post a Comment