You may need to wait a few frames before the width and height are known,
it needs to measure and draw itself.  What happens if you use a button
to check the width and height so that you can wait briefly?  If that
works just write code to wait 3 or 4 frames and see if you can process
everything then.

Matt

-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of bhaq1972
Sent: Wednesday, January 18, 2006 7:54 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Flex 1.5 how to get Menu height and width

Hi
I'm looking at the flex 1.5 livedocs example of how to create a Menu -
http://livedocs.macromedia.com/flex/15/asdocs_en/index.html (at the 
bottom).

I cant seem to get the height and width of the Menu after creating the 
menu. eg

myMenu = Menu.createMenu(panel, myMenuData);

trace(myMenu.height); //always 0
trace(myMenu.width); //always 0

How do i get the actual height and weight.

TIA






--
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



 




--
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