I'm trying to control whether a button is rendered programmatically.

But the code below returns the following error:


Initializer for 'visible': cannot parse value of type Boolean from text
'isButtonVisible()'.


Please advise.


<mx:DataGridColumn headerText="Phone number" dataField="phone_number"/>

<mx:DataGridColumn headerText="Reset pin" >

<mx:itemRenderer>

    <mx:Component>

<mx:Button label = "Reset pin" enabled="false" visible="isButtonVisible()"
/>

    </mx:Component>

</mx:itemRenderer>

</mx:DataGridColumn>


private function isButtonVisible():Boolean{

return false;

}

Reply via email to