# Actionscript error

**URL:** <https://forum.kirupa.com/t/actionscript-error/37702>\
**Category:** Uncategorized\
**Created:** [December 13, 2003, 2:08am UTC](https://forum.kirupa.com/t/actionscript-error/37702 "2003-12-13T02:08:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![minimalistik](https://avatars.discourse-cdn.com/v4/letter/m/e47774/32.png) [@minimalistik](https://forum.kirupa.com/u/minimalistik)\
**Post date:** [December 13, 2003, 2:08am UTC](https://forum.kirupa.com/t/actionscript-error/37702/1 "2003-12-13T02:08:41Z")

</div>

ive started making a menu but nothing technical just animation to a “rectangular shape” as and converted to an mc…

Ive applied actions to the shape mc like this:

onClipEvent (enterFrame) {  
var speed = 4;  
var viscosity = 1.3;  
difference = whld5 - this.\_width;  
xvelocity = (xvelocity + (difference / speed)) / viscosity;  
this.\_width = this.\_width + xvelocity;  
difference = hhld5 - this.\_height;  
yvelocity = (yvelocity + (difference / speed)) / viscosity;  
this.\_height = this.\_height + yvelocity;  
}  
on (rollOver) {  
if (oneup == “no”) {  
\_global.whld1 = 143.2;  
\_global.hhld1 = 87.5;  
\_root.b1.\_x = xhld1;  
\_global.whld2 = 143.2;  
\_global.hhld2 = 87.5;  
\_root.b2.\_x = xhld2;  
\_global.whld3 = 143.2;  
\_global.hhld3 = 87.5;  
\_root.b3.\_x = xhld3;  
\_global.whld4 = 143.2;  
\_global.hhld4 = 87.5;  
\_root.b4.\_x = xhld4;  
\_global.whld5 = 143.2;

}  
on (release) {  
if (oneup == “no”) {

}

**but the output windows says:**

Scene=Scene 1, Layer=Layer 1, Frame=1: Line 28: on handlers may not nest within other on handlers  
on (release) {

Scene=Scene 1, Layer=Layer 1, Frame=1: Line 31: Syntax error.  
}

Scene=Scene 1, Layer=Layer 1, Frame=1: Line 11: Statement block must be terminated by ‘}’  
on (rollOver) {

Scene=Scene 1, Layer=Layer 1, Frame=1: Line 31: Syntax error.  
}

whats wrong with the script?
