I'm getting this error while trying to call play() on a glow effect
I've created. I'm trying to call play() from within a function that is
called as a result of a bindable value being changed. Basically I have
a data model with bindable data and a Label which displays the data.
When the data changes, I'm trying to play the glow effect on the label
to highlight the change. What am I doing wrong?
All these objects are defined in the same .mxml file. Relevant
snippets are :
<myNS:Order id="order">
...
(inside script tag)
public function getQtyDisplay(currentQty:int, maxQty:int):String {
var result:String = currentQty+"("+maxQty+")";
qtyGlow.play();
}
...
<mx:Glow id="qtyGlow" target="qtyDisplay" color="0x99FF66"/>
...
<mx:Label id="qtyDisplay" text="{getQtyDisplay(order.currentQty,
order.maxQty)}"/>
The getQtyDisplay() function works fine w/out the play() call. After I
added it I started getting this error, so I wrapped the play() call in
a try/catch block.