Cheers Eamonn, I have checked that article already but I couldn't find
an answer, I guess I need a more nuts and bolts answer :)
Thanks
On 7 Nov 2008, at 11:28, Eamonn Faherty wrote:
Have you seen?
http://www.gskinner.com/blog/archives/2008/04/failure_to_unlo.html
HTH
Eamonn
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
] On Behalf Of Alistair Colling
Sent: 07 November 2008 11:09
To: Flash Coders List
Subject: [Flashcoders] Can't remove loaded SWF AS3
Hi there, I'm aware that if you load a SWF in AS3 it will still exist
unless you null it's instance. I'm loading in an external SWF but I
can't seem to get rid of it!
If anyone can let me know soon I would be super-grateful.
Thanks!
Here's my code:
private function startLoad(s:String):void
{
try{
mLoader = null;
}
catch(e:*){
trace("unalble to null loader");
}
try{
mLoader.unload();
}
catch(e:*){
trace("unable to unload as was nulll");
}
mLoader = new Loader();
mRequest = new URLRequest(s);
mLoader.contentLoaderInfo.addEventListener(Event.COMPLETE,
onCompleteHandler);
mLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS,
onProgressHandler);
mLoader.load(mRequest);
}
private function onCompleteHandler(loadEvent:Event):void
{
loadedSWF = null;
trace("loaded");
anim.contentLoaded(loadEvent.currentTarget.content);
loadedSWF = loadEvent.currentTarget.content;
if (urlStr=="people.swf"){
loadedSWF.x = -345;
}else{
loadedSWF.x = -345;
}
}
--------------------------------------------------------------------------
Alistair Colling
Interactive Developer
FPP Brand Communications (Newcastle upon Tyne)
The Courtyard
Dinsdale Place
Sandyford
Newcastle upon Tyne NE2 1BD
Telephone: +44 (0)191 261 6662
Fax: +44 (0)191 233 2511
This transmission is confidential and intended solely for the person
or organisation to whom it is addressed.
It may contain privileged and confidential information. If you are
not the intended recipient, you should not
copy, distribute or take any action in reliance on it. If you have
received this transmission in error, please
notify the sender at the e-mail address above.
FPP Design Limited. Reg. Office: The Courtyard, Dinsdale Place,
Sandyford, Newcastle upon Tyne NE2 1BD.
Registered Number 3775564. Registered in England and Wales. Visit
our website at http://www.fpp.net/
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
--------------------------------------------------------------------------
Alistair Colling
Interactive Developer
FPP Brand Communications (Newcastle upon Tyne)
The Courtyard
Dinsdale Place
Sandyford
Newcastle upon Tyne NE2 1BD
Telephone: +44 (0)191 261 6662
Fax: +44 (0)191 233 2511
This transmission is confidential and intended solely for the person or
organisation to whom it is addressed.
It may contain privileged and confidential information. If you are not the
intended recipient, you should not
copy, distribute or take any action in reliance on it. If you have received
this transmission in error, please
notify the sender at the e-mail address above.
FPP Design Limited. Reg. Office: The Courtyard, Dinsdale Place, Sandyford, Newcastle upon Tyne NE2 1BD.
Registered Number 3775564. Registered in England and Wales. Visit our website at http://www.fpp.net/
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders