flash scroller help
- Started
- Last post
- 14 Responses
- SlashPeckham0
the flash guy i'd lined up for this gig bailed out on me... i hardly ever do this bit
- dippy0
I'm a Flash n00b so I kinda just learned these things too, a coupla weeks ago. The last time I played with Flash, it was Version 5.0, LOL.
- dippy0
make a movieclip containing your image, name it image_clip or something, then drag an instance of the scrollpane onto the stage, and modify the properties of the scrollpane. i.e. in the Scroll Content part, type in "image_clip" (without the quotes).
Under Linkage in your image movieclip, click on Export for Actionscript.
This might be a little confusing, so just read the tutorial in Flash Help.
- SlashPeckham0
so how do i do it to an image then?
- dippy0
the scrollbar i think is just for text
- dippy0
you can scroll anything with the "scrollpane" component. Just link it up.
- SlashPeckham0
that mx component thingy is handy - can i scroll images with it?
- dippy0
i'm tellin ya, just use the Flash MX scrollbar or scrollpane component. They're under Components, so you just drag em onto the stage and go from there.
Or try this:
- caseyc0
It's the _root references. Think hard, concentrate.
- SlashPeckham0
bump
- SlashPeckham0
so where do you think i can change this? the target i'm calling it onto is called 'foliolist'
- fusionpixel0
LOL
Well, dont give in the Component crap. create your own and rule the world!!!!
- SlashPeckham0
um
- dippy0
why don't you just use the scroller component in Flash?
- SlashPeckham
http://www.flashkit.com/movies/S…
this scroller is great, however when I load it onto another movieclip as an external file it doesn’t work
Any ideas?
Asifheres the code
// Define the Scroll Area
top = _root.movMask._y;
bottom = _root.movMask._y+_root.movMask...
left = _root.movMask._x;
right = _root.movMask._x+_root.movMask...
// Bring all objects to the Scroll Area
_root.movIn._y = top;
_root.movIn._x = left;
_root.movScroller._y = top;
_root.movScroller._x = right;
// When the Scroller is Dragged
_root.movScroller.onMouseDown = function() {
if (hitTest(_root._xmouse, _root._ymouse)) {
startDrag("_root.movScroller", false, right, top, right, bottom);
}
};
// when the Scroller is Released
_root.movScroller.onMouseUp = function() {
stopDrag();
};
// Update Position every 10 milliseconds
setInterval(Update, 10);
function Update() {
var ratio = (_root.movIn._height-_root.movMa...
_root.movIn._y = ((_root.movMask._y-_root.movScro...
}