the "includeInLayout" property may also be helpful to you in this case, try:

includeInLayout="{outerDocument.fncVisible()}"

 

From: [email protected] [mailto:[email protected]] On Behalf 
Of Angelo Anolin
Sent: Thursday, May 20, 2010 2:46 PM
To: [email protected]
Subject: [flexcoders] Set Width of An Item Renderer Component Based on Visible 
Property of the Control

 

  

Hi FlexCoders,

 

I have declared an in-line item renderer in my datagrid:

 

<mx:DataGridColumn headerText="Test" textAlign="center" sortable="false">

  <mx:itemRenderer>

    <mx:Component>

      <mx:HBox horizontalAlign="center" >

        <mx:LinkButton id="lnk1" label="Link 1" 
visible={outerDocument.fncVisible()}" width="{???}"/>

        <mx:LinkButton id="lnk1" label="Link 1" />

        <mx:LinkButton id="lnk1" label="Link 1" />

      </mx:HBox>

    </mx:Component>

  </mx:itemRenderer>

</mx:DataGridColumn>

 

 

as you may see, I am determining the visibility of the link button via a 
function.  What I want to achieve is that if the linkbutton contrl is 
invisible, the width should be 0, but if it is visible, then width should be 
100.

 

How do I pass in a function for the width of the control whether it's 
visibility is set to true or false?

 

Thanks.

 



<<image001.jpg>>

<<image002.jpg>>

Reply via email to