A Flash Developer Resource Site

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Dec 2012

    Help loading an external SWF

    Hey guys, So I've pretty much finished making a site, I just need a gallery. To make it easily edited I decided to use the
    Photo Gallery Maker program, found here: http://www.photogallerymaker.com/

    But I keep getting an error loading this and I have no idea how to fix it, the error is:

    TypeError: Error #1009: Cannot access a property or method of a null object reference.
    at GalleryLoader()[E:\Projects\GalleryMaker\FlexSource\GalleryLoader\ src\GalleryLoader.as:23]

    The code I'm using is this:

    import flash.net.URLRequest;
    import flash.display.Loader;
    import flash.events.Event;
    import flash.events.ProgressEvent;
    function startLoad()
    var mLoader:Loader = new Loader();
    var mRequest:URLRequest = new URLRequest("WG3.swf");
    mLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onCompleteHandler);
    mLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, onProgressHandler);
    function onCompleteHandler(loadEvent:Event)
    function onProgressHandler(mProgress:ProgressEvent)
    var percent:Number = mProgress.bytesLoaded/mProgress.bytesTotal;

  2. #2
    Senior Member
    Join Date
    Nov 2012
    Your error looks like it is coming from the actionscript file for the GalleryLoader. The Error #1009 comes from trying to talk to something that is not there... Check this article: http://curtismorley.com/2007/08/15/f...ect-reference/

    Does the gallery play fine in its own swf? and now you are having trouble incorporating it into your file?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Click Here to Expand Forum to Full Width

HTML5 Development Center

By using this site, you agree to the Privacy Policy