I have a button in flash and I want to generate an automatic color for my square.
I have this function
private function btnClick(event:MouseEvent):void
{
var mycolor :ColorTransform = new ColorTransform();
mycolor.color = (Math.random() * 0xFFFFFF);
parcare.transform.colorTranform = mycolor;
}
I get this error
: 4 Error: Access of undefined property parcare. parcare.transform.colorTranform = mycolor;
Do you know how can I solve it? Thank you!