Expand my Community achievements bar.

DataGridsColums and CheckBoxes

Avatar

Level 1
HI Guys,



I'm trying to set the value of a checkbox in a datagrid
column, to the result of some value in a method of a script that
i'm running, I have the following code;






quote:





<mx:Script>

<![CDATA[



public function someMethod():Boolean{

if(someVariable){

return true;

}

else {

return false;

}

}

]]>

</mx:Script>

...



<mx:DataGridColumn dataField="onSale"

headerText="On Sale"

width="80">

<mx:itemRenderer>

<mx:Component>

<mx:CheckBox selected="false">



</mx:CheckBox>

</mx:Component>

</mx:itemRenderer>

</mx:DataGridColumn>











However when I do this I get the following error;



"Call to a possibly undefined method someMethod"



why is this?
0 Replies