User Guide
on() 191
Example
In the following script, the startDrag() function executes when the mouse is pressed, and the
conditional script is executed when the mouse is released and the object is dropped:
on (press) {
startDrag(this);
}
on (release) {
trace("X:"+this._x);
trace("Y:"+this._y);
stopDrag();
}
See also
onClipEvent()