ActionScript 3.0 :: Getting Error 2007 When Loading SWF Files
Apr 3, 2011
I am just learning ActionScript3 and am trying to create a fla file that loads 3 external SWF. I have already created and saved the 3 SWFs and they are all saved in the same folder. I have given them the names "A.swf" "B.swf" and "C.swf" so they are easy for me to keep track of. I created the actionscript below and placed it in the first frame of my parent file which is saved in the same folder.
import flash.display.MovieClip;
import flash.display.Loader;
var swfContainer:MovieClip;
var swfLoader:Loader = new Loader();
[Code] .....
When I insert the filename in the URLRequest statement "A.swf" and test the movie it works loading the swf movie and playing it. When I swap either the "B.swf" or "C.swf" file names in the place of the "A.swf" it doesn't work. I end up with no swf file loaded or played on the stage. I also get the following error statement. But I am confused because it is in the Output Tab not the Error Tab which does not report any errors.
TypeError: Error #2007: Parameter child must be non-null.
at flash.display:isplayObjectContainer/addChild()
at SWFadMovieClips_fla::MainTimeline/loaderCompleteHandler()
Although I shouldn't be too surprised as it is written for use with CS.3 and I am using CS.5. Eventually my goal is to create one fla file which loads and plays in succession the three separate swf files in one package.
View 0 Replies
Similar Posts:
Jan 18, 2011
I have a main SWF file, in AS3, wich works as holder/loader for many other SWF files (sections). I had to make a new section ("verano.swf"), but I did it in AS2. When I try to load it, I get the following error:
TypeError: Error #2007: Parameter child must be non-null.
at flash.display::DisplayObjectContainer/addChild()
at Tabu/onCompleteHandler()
[code].....
View 1 Replies
Jun 21, 2009
I'm currently working on a game and I'm trying to work out a way to load images externally and display them on the screen.But the problem is it won't load them correctly and display them, as seen below...
ERROR:
Code:
TypeError: Error #2007: Parameter child must be non-null.
at flash.display::DisplayObjectContainer/addChild()
at main_fla::MainTimeline/frame2()
[code]....
On the second frame i got:
Code:
addChild(weapons['MP5']);
View 7 Replies
Jul 5, 2010
I have a class that creates a navBar with some buttons. Each button loads an external .swf and everything is working just fine BUT the code is really awkward. I also wanted to use TweenLite to add transitions from section to section.I also wanted to handle the "section change" process from yet another Class (SectionChange) but whenever I try it I fail miserably. Here's what I have (including the vars), without the SectionChange Class, that's working.
private var _app:Sprite;
private var _navData:Array;
private var _loader:LoadDisplayObject;[code]....
I don't know what I'm doing wrong here but I get tons of errors with this code.
edit: Now that I'm adding the _sectionChange to the display list I only get the following error: TypeError: Error #2007: Parameter child must be non-null.
View 2 Replies
May 5, 2009
I'm trying to load different XML content with buttons. Basically all i'm able to do right now is have the XML load when I test the movie. Outside of that I haven't been able to get my script correct to call up the XML when a button is clicked.Here's the code i've been trying:
var content_req: URLRequest = new URLRequest ("http://www.kirupa.com/net/files/sampleXML.xml");
var content_ldr: URLLoader = new URLLoader (content_req);
content_ldr.addEventListener(Event.COMPLETE, onComplete);[code]....
So this is wrong because when i export my movie and click on the button I get this message:
TypeError: Error #2007: Parameter text must be non-null. at flash.text::TextField/set text()
at dynamicText_fla::MainTimeline/getnewText()
Also, when the XML does load into the text field, I'm getting the entirety of the XML document, not just the bits of information that I want. It wasn't doing this before when I would just export the movie and the XML information would come up in the output panel.
View 1 Replies
Apr 23, 2012
I have One SWF loading Two External SWFs seprately that have dataGrid components in them. The Externals load and run fine on their own but when I try to load them into CORE SWF I get ....
TypeError: Error #2007: Parameter child must be non-null.
at flash.display:isplayObjectContainer/addChildAt()
at fl.controls::BaseButton/drawBackground()[code]..............
View 2 Replies
Feb 17, 2011
Code is working but i am getting the following error and it is driving me insane:
TypeError: Error #2007: Parameter hitTestObject must be non-null.
at flash.display:isplayObject/_hitTest()
at flash.display:isplayObject/hitTestObject()
at PlatformGame/checkCollisions()
at PlatformGame/gameLoop()
Here is my Frankenstein code...i just need it working. Error happens when I remove the numOfKeys-- where I examine the level. Had to remove some code because of length when posting here on FK.
View 1 Replies
Sep 14, 2010
i added a display object like so:
var backButton:BtnSMenu = new BtnSMenu();
backButton.name = "backButton";
mainHolder.parent.parent.parent.addChild(backButton);
but then later in the code i want to remove the child so i did this:
mainHolder.parent.parent.parent.removeChild(getChildByName("backButton"));
but i get this error:TypeError: Error #2007: Parameter child must be non-null.
View 6 Replies
Aug 30, 2009
I have three dynamically created MCs on stage and when I press on first one I want to initialize ENTER_FRAME function , but Im getting this error:
[Code]...
View 4 Replies
Jun 25, 2009
I am currently writing some server login scripts which integrate with flash (so you type your details into flash then it sends the data to php). I have done plenty of sending and recieving to and from php before and never had any issues. However just recently I have been getting an annoying error which reads:
[Code]...
View 6 Replies
Mar 23, 2009
I have an application which loads external .swf files into an empty movie clip. This works fine the the Flash Development environment however when I run it in IE then dont load, and when run in FireFox I get the following error: -Error #2044: Unhandled SecurityErrorEvent:.text=Error #2140: Security sandbox violation: file:///C:/Users/Tom iccirilli/Desktop/test/tester.swf cannot load ile:///C:/Users/myname/Desktop/test/TriviaGame.swf. Local-with-filesystem and local-with-networking SWF files cannot load each other.
View 1 Replies
Jan 13, 2011
i was loading a images from web for a polio page.. and for god shake, the uploading of image using Loader class for .PNG file alwz stuck at 13765 Bytes and Threw error saying the URL not available .. i was sure that the image was there and it loaded upto 13KB ... this was damn freaking.. i took hours tryin to debug it.. the fix was so simple.. the image file was to be renamed .png rather than .PNG and all worked fine... How come and from when Flash started treating .png and .PNG in different way and why the image loaded to 13KB and said invalid url..?
View 0 Replies
Nov 2, 2009
I'm receiving the following error:
TypeError: Error #2007: Parameter url must be non-null.
[Code]...
View 4 Replies
Sep 18, 2011
I am developing a target game with Touch Event so that you can use-up all your fingers, but I can't remove the enemy from the stage. I'll paste the code
public function onTouchBegin(e:TouchEvent):void
{
var dot:Sprite = this.getCircle();
[code]........
View 18 Replies
Aug 3, 2011
I'm getting this error:
TypeError: Error #2007: Parameter child must be non-null.
at flash.display::DisplayObjectContainer/addChildAt()
at fl.controls::BaseButton/drawBackground()
[code]....
View 1 Replies
Apr 8, 2009
I have a movieclip that displays a slideshow. Starting a few days ago I get a error message from Flash Player 10 saying
"TypeError: Error #2007: Parameter url must be non-null.
at flash.display::Loader/_load()
at flash.display::Loader/load()
at slides/switchPhoto()
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()"
Here is the actionscript package for the error
package{
import flash.display.MovieClip;
import flash.display.Loader;
import flash.display.LoaderInfo;
import flash.events.*;
[Code] .....
View 5 Replies
Apr 20, 2009
I am doing a project in which I need to open and close MovieClips. I have my Scene1 which loads the first MC (named "page1") then page1 plays and I would like it to unload itself and load the MC named "Page2" and so on up to page 10 ...
On the last frame of the MC "page1" I have this code:
stop();
stage.addEventListener(MouseEvent.CLICK, animate2);
function animate2 (event:MouseEvent):void {
stage.removeChild(stage.getChildByName("clip1"));
var clip2:MovieClip = new page2();
addChild (clip2);
}
But all I get is this error message:
TypeError: Error #2007: Parameter child must be non-null.
at flash.display:isplayObjectContainer/removeChild()
View 2 Replies
Jan 23, 2011
I am working on a fairly simple drag and drop based Flash piece and I have come across an Output Error which I was hoping somebody could give me a better understanding of.As a very brief back-story to my problem, I have two borders on both the far left and right of my movie and the alpha is set to 0 on both of these MovieClips; now I have labels within the movie and I am using the hitTestObject command with an IF statement stating that should the label_mc hit either border1_mc or border2_mc on Mouse Move then execute some code; my problem is that in my Output panel I have now received the error:
TypeError: Error #2007: Parameter hitTestObject must be non-null.
I am not sure about this particular error and would be interested if anybody had any ideas on a fix or solution as I want to understand what is going on with this; I read around some forums which said that when you use hitTestObject the console is listening out for the intersect and that if you move on to different labels later in the movie if the MovieClips you intend to hit aren't present throughout the piece it may cause this error (but I might and probably am wrong).
View 3 Replies
Mar 30, 2009
There are hundreds of threads on the web about unloading movie but none of them work. For example, the code below gives this error: TypeError: Error #2007:
Code:
var alert:Boolean=true;
if (loaderInfo.url!="someurl") {
removeSwf();
[code]...
View 4 Replies
Jul 21, 2009
"TypeError: Error #2007: Parameter child must be non-null.
at flash.display:isplayObjectContainer/addChild()
at newLFXsite_fla::MainTimeline/onClick()"
so i get this error every time i click on the about page after the homepage appears on screen, from what i know im doing everything right, but i guess theres something wrong that i cant see.
[Code]...
View 2 Replies
Jun 11, 2009
this is the error [code]And the frame labled homeMenu_MC.i can't seem to figure out what is going on, i'm still pretty new to AS3 and AS period so I'm not sure exactly what the "child" is.All I know is it loads and the btn glow works right the menu just doesn't come up when your roll over the navBar_mc everytime i roll over it i see in the output the error code.
View 2 Replies
Jul 10, 2009
This error comes up every single time I try to run a simple AS3 tutorial flash file on my website..Things I did:-server php support check was run. (success!)-using html to call php for a simple registration form.(success!)-ANY flash file to do a two way communication with a php file ( FAILS!)I tried maybe 10 different swf files and php files that go with them.
View 5 Replies
Aug 26, 2009
We are getting ready to start trying to convert our older content to AS3.To this end, I have been trying to develop what I though would be a relatively simple. It just an attempt at an adaptable mc button class that my animators and designers can kind of "plug and play" so I can spread out some of the workload.I keep getting "Error 2007 Parameter listener must be non-null". I understand why its throwing an error. simplified block:
Package{
import flash.display.MovieClip
import flash.events.[code].......
View 1 Replies
Sep 24, 2009
i've a problem with a MC containing 3 3D nested animated MC. When i place this MC on the main TLine, it give me
error #2007 Parameter blendMode must be non-null.
The I tried to set the blendmode of the 3 nested MC in the nested timeline:
nestedMC.blendMode = BlendMode.NORMAL;
but it keep giving me error...
View 4 Replies
Jan 30, 2010
i have the following script , and its giving me this error...this occured after i wrote the last line... which will unload the about section if home is pressed...
var imageRequest:URLRequest = new URLRequest("home.swf");var imageLoader:Loader = new Loader();imageLoader.load(imageRequest);addChild(imageLoader);
imageLoader.x = 0;imageLoader.y = 140;
[code]....
View 11 Replies
Mar 26, 2010
The slideshow its referring to is a something I purchased online and is embedded into my movie.Does it mean I need to put and onComplete function on the page thats loading this? Is it for the xml or the slideshow movie?
Error #2007: Parameter listener must be non-null. at flash.events::EventDispatcher/addEventListener() at slideshow_fla::TheWholeSlideshow_1/xmlLoaded() at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at flash.net::URLLoader/onComplete()
View 16 Replies
Jul 28, 2010
I'll try to be as thorough as possible so there isn't any question as to what is going on or what it is I'm trying to acheive. I've been asked to build a digital catalog for my company's products in Flash.The program is simply an organized way to view files that will be contained with in the same folder as the swf file. The program consists of one scene with five buttons that control the timeline, and each different part of the timeline has a movieclip containing the buttons that open the different files. There are only two of these types of buttons: one is bu_video and the other is bu_brochure. They both have several button instances differentiating between different products. For example: Product A has two buttons: bu_video (instance name videoA) and bu_brochure (instance name brochureA). Here is the code I'm using to get the desired effect.
mc_cutButtons.addEventListener(MouseEvent.MOUSE_DOWN, action, false, 0, true);mc_cutButtons.addEventListener(MouseEvent.MOUSE_OVER, action, false, 0, true);mc_cutButtons.addEventListener(MouseEvent.MOUSE_OUT, action, false, 0,
[code].....
View 6 Replies
Dec 22, 2011
I am getting this strange error message in my ItemRenderer.
TypeError: Error #2007: Parameter antiAliasType must be non-null.
at flash.text::TextField/set antiAliasType()
package xxx
[code].....
View 1 Replies
Oct 23, 2009
when i am executing the below code i am getting error as TypeError: Error #2007: Parameter text must be non-null. at flash.text::TextField/set text() at try_fla::MainTimeline/showNextQuestion() at try_fla::MainTimeline/onClick()
[Code]....
View 1 Replies
Oct 26, 2009
TypeError: Error #2007: Parameter type must be non-null.
at flash.events::EventDispatcher/addEventListener()
at INDEXnew_fla::Symbol31_120/go()
stop();
[code]......
View 3 Replies