# Alter function code?!

**URL:** <https://forum.kirupa.com/t/alter-function-code/177493>\
**Category:** flash\
**Created:** [February 2, 2006, 12:30pm UTC](https://forum.kirupa.com/t/alter-function-code/177493 "2006-02-02T12:30:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Claire\_murphy](https://avatars.discourse-cdn.com/v4/letter/c/43a26b/32.png) [@Claire\_murphy](https://forum.kirupa.com/u/Claire_murphy)\
**Post date:** [February 2, 2006, 12:30pm UTC](https://forum.kirupa.com/t/alter-function-code/177493/1 "2006-02-02T12:30:04Z")

</div>

Hi peeps…good afternoon.

I’m looking to add an element to this function to make my text fade. On (release) of my ‘biog’ button this function starts. But also I need my text on the page to fade from 100 to 0 on release, before this function begins. I’ve tried applying code that i have but can’t get it to wrk. Not sure how these functions work exactly and no matter how much reading I do I can’t get this right.

scrollIt = function() {  
this.onEnterFrame=function() {  
if (\_root.container1.SUB.\_x\>440) {  
\_root.container1.SUB.\_x += -30;  
} else if (\_root.container1.SUB.\_x\>-30) {  
\_root.container1.PAGE.\_x += (-40-\_root.container1.PAGE.\_x)/8; \_root.container1.SUB.\_x += (0-\_root.container1.SUB.\_x) /2;  
}  
else { delete this.onEnterFrame;  
}  
}  
}
