I've got a movie that calls a class which loads an array. I can reference that array from the movie using:
Actionscript Code:
trace("config "+this.course.ConfigTitles.toString());
(ooooo...new as tag...)
Now, I'm using the following code to load another movie:
Actionscript Code:
var request:URLRequest = new URLRequest("media/conf"+Number(Number(selectedConfig)+Number(1))+".swf");
var loader:Loader = new Loader()
loader.load(request);
imagePH_mc.addChild(loader);
and, in that movie, I play a movie and, when it's finished, I need to display the content from the array. I've tried:
Code:
trace("ComponentsTitle "+MovieClip(parent).course.ConfigTitles.toString());
and I get the following error:
Code:
TypeError: Error #1034: Type Coercion failed: cannot convert flash.display::Loader@267da581 to flash.display.MovieClip.
at conf1_fla::MainTimeline/setBackImage()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at fl.video::FLVPlayback/http://www.adobe.com/2007/flash/flvplayback/internal::handleVideoEvent()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at fl.video::VideoPlayer/http://www.adobe.com/2007/flash/flvplayback/internal::httpDoStopAtEnd()
at fl.video::VideoPlayer/http://www.adobe.com/2007/flash/flvplayback/internal::httpNetStatus()
If I remove the trace statement, it works fine with no errors. I've also tried it with 2 and 3 "parent" references with slightly different errors:
Using 2 "parent" references:
Code:
TypeError: Error #1010: A term is undefined and has no properties.
at conf1_fla::MainTimeline/setBackImage()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at fl.video::FLVPlayback/http://www.adobe.com/2007/flash/flvplayback/internal::handleVideoEvent()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at fl.video::VideoPlayer/http://www.adobe.com/2007/flash/flvplayback/internal::httpDoStopAtEnd()
at fl.video::VideoPlayer/http://www.adobe.com/2007/flash/flvplayback/internal::httpNetStatus()
Using 3 "parent" references:
Code:
ReferenceError: Error #1069: Property course not found on Configurator and there is no default value.
at conf1_fla::MainTimeline/setBackImage()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at fl.video::FLVPlayback/http://www.adobe.com/2007/flash/flvplayback/internal::handleVideoEvent()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at fl.video::VideoPlayer/http://www.adobe.com/2007/flash/flvplayback/internal::httpDoStopAtEnd()
at fl.video::VideoPlayer/http://www.adobe.com/2007/flash/flvplayback/internal::httpNetStatus()
Any ideas??
Thanks!!