Hi,

I'm having trouble displaying a Bitmap with Flex 2.
Just as in the Help documentation i've added the following code:

var pictLdr:Loader = new Loader();
var pictURL:String = "image.jpg"
pictLdr.addEventListener(Event.COMPLETE, showPict);
var pictURLReq:URLRequest = new URLRequest(pictURL);
pictLdr.load(pictURLReq);

I also added an event listener COMPLETE.

Now i want to add a bitmap to an VBox in my project.

function showPic(event:Event) : void {

    var bmp:Bitmap = new Bitmap(pictLdr.content);

    vboxImageContainer.addChild(bmp)
}

I can't get it done. I'm getting the runtime error code 1009 (null has no
properties).

Good someone help me out!

Richard



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to