Posted By

marzsman on 04/04/11


Tagged

image load loader


Versions (?)

Load image


 / Published in: ActionScript 3
 

Load an image

  1. var ldr:Loader = new Loader();
  2. ldr.load(new URLRequest("template.jpg"));
  3. ldr.contentLoaderInfo.addEventListener(Event.COMPLETE, loaded, false, 0, true);
  4. function loaded(evt:Event):void
  5. {
  6. addChild(evt.target.content);
  7. }

Report this snippet  

You need to login to post a comment.