# Scrolling Menus/MC controlled by ActionScript - HELP!

**URL:** https://forum.kirupa.com/t/scrolling-menus-mc-controlled-by-actionscript-help/20533
**Category:** flash
**Created:** [May 9, 2003, 9:23pm UTC](https://forum.kirupa.com/t/scrolling-menus-mc-controlled-by-actionscript-help/20533 "2003-05-09T21:23:52Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![timmer](https://avatars.discourse-cdn.com/v4/letter/t/bb73d2/32.png) [@timmer](https://forum.kirupa.com/u/timmer)
#### Post date: [May 9, 2003, 9:23pm UTC](https://forum.kirupa.com/t/scrolling-menus-mc-controlled-by-actionscript-help/20533/1 "2003-05-09T21:23:52Z")

</div>

Hey all -

Anybody out there who can lend a hand on this one would be a LIFESAVER.

My issue is best described by a working example. Check it out:  
go to [http://www.ronniewood.com](http://www.ronniewood.com)  
and click on Music --\> History

I’m looking to create something similar, in which a MC will move around (slide left-right) based on how the user manipulates a scroll bar, much like in the [ronniewood.com](http://ronniewood.com) site. But I’ve got no idea where to start. If anyone’s got any hints, or if the concept looks familiar - I’d be most grateful for some feedback.

Thanks folks,  
Tim  
[tlyons@berklee.edu](mailto:tlyons@berklee.edu)

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [May 10, 2003, 6:21am UTC](https://forum.kirupa.com/t/scrolling-menus-mc-controlled-by-actionscript-help/20533/2 "2003-05-10T06:21:00Z")

</div>

You could make something like that with a movieclip which contains all of the content, then mask it so you wouldn’t see the entire mc but only a rectangle in the middle of the screen.

I"m not sure whether you use Flash MX or not, but since this thread was posted in the Flash MX forum …

Place the mc on the postion you want it to start. Remember this x position or write it down somewhere. Now move it to the position you want it to be if the button is pressed. Also, remember this x position.

Now make a new movieclip and call it slidercontrol or somethin’ like that. Apply this code to it:

[AS]onClipEvent(load){  
\_root.slider = startxposition  
}  
onClipEvent(enterFrame){  
\_root.movieclipyouwanttomove.\_x = \_root.slider-(\_root.slider-\_root.movieclipyouwanttomove.\_x)/1.2  
}[/AS]

Now for the button when clicked you want the mc to move, apply this as :

[AS]on (release){  
if (\_root.slider = startxposition){  
\_root.slider = endxpostion  
} else {  
if (\_root.slider = endxposition){  
\_root.slider = startxposition  
}  
}  
}[/AS]

If you have any questions left, pm me and I will help you out 🙂
