rowHeight is a property on List-based components. MenuBar does not
derive from ListBase so you cannot set rowHeight on the MenuBar. You
need to set it on the individual menus the MenuBar pops up.

You can use the getMenuAt() method to grab each individual menu from the
MenuBar and set rowHeight there. Try something like:

<mx:XML id="dp">
      <node label="root">
            <node label="one">
                  <node label="child" />
            </node>
            <node label="two">
                  <node label="child" />
            </node>
            <node label="three">
                  <node label="child" />
            </node>
      </node>
</mx:XML>

<mx:Script>
<![CDATA[
import mx.controls.Menu;

private function setRowHeights(mb:MenuBar):void
{
      for (var i:int = 0; i < dp.children().length(); i++)
      {
            mb.getMenuAt(i).rowHeight = 50;
      }
}
]]>
</mx:Script>

<mx:MenuBar id="mb" dataProvider="{dp}" showRoot="false"
labelField="@label" creationComplete="setRowHeights(mb);"/>

-deepa

-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Sascha Balkau
Sent: Tuesday, May 02, 2006 10:06 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Two Flex 2 Components Questions



>
> > The opendelay is gone but the rowHeight hasn't changed. Is there
anything
> > else I need to take into account to make this work?
>
> I think rowHeight is a property (not a style).
>
> Manish

It seems not! If I try to use it as a property on the MenuBar tag I get
an
error.

Sascha




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




SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




Reply via email to