In this case, your function is not referencing anything Bindable. Something
like this may work, but please clarify - if this is not what you're looking
for:

[Bindable]
private var bindableProp:String;

private function isEnabled( s:String ):Boolean
{
...
}

<mx:ComboBox id="cb" enabled="{isEnabled( bindableProp )}"/>

On 11/28/06, ben.clinkinbeard <[EMAIL PROTECTED]> wrote:

  There was a similar question asked here recently but my needs are
different so I am starting a new thread. My needs are as follows: I
have a ComboBox whose enabled state needs to be determined by several
factors, thus the need for a custom method. The problem is that this
doesn't seem to work, no matter how I try it. Am I missing something
or is this just not possible (meaning I have to set a property and
bind to that)? Fake sample code below:

[Bindable]
private function isEnabled():Boolean
{
if(conditionA)
{
if(conditionB)
{
return true;
}
else
{
return false;
}
}
}

<mx:ComboBox id="cb" enabled="{isEnabled()}"/>

Thanks,
Ben




--

: : ) Scott

Reply via email to