Click to See Complete Forum and Search --> : Button in a movieclip, to affect another movieclip?
sheepo-designs
02-11-2008, 06:58 PM
I am mking a small website, where users can view different HTML colours. I have a movieclip where the "slides" of colour are shown, and another movieclip with the buttons and navigation.
How do I use the buttons in "movieclip1" to affect the slides in "movieclip2"
I found this in a search, but I'm not sure if I have the same problem:
If you want to load a swf from outside to a movie clip then try this ...
m1.loadMovie("file.swf",0);
put this code in the frame action.
as m1 is the movieclip instance.
Then you can stop and play the movie by puting these code in stop and play buttons.
on (release) {
m1.stop();
}
on (release) {
m1.play();
}
sheepo-designs
04-02-2008, 04:31 PM
I am still having this problem! I had to abndon this idea but now a client wants it, PLEASE HELP ME I CAN'T FIND THIS ANYWHERE!!!!
magicplant
04-02-2008, 04:48 PM
Hi,
So you have 2 movie clips. One has your buttonsin. The other has your sides one on each frame lets say)
So you give your slides movie clip an instance name of slides_mc in the properties panel.
Now your buttons each have an instance name of lets say butt1, butt2, etc.
Within your buttons movie clip make a different layer and open the actions panel.
type in the following code....
butt1.onRelease=function(){
_root.slides_mc.gotoAndPlay(1);
}
butt2.onRelease=function(){
_root.slides_mc.gotoAndPlay(2);
}
butt3.onRelease=function(){
_root.slides_mc.gotoAndPlay(3);
}
etc.
Or you can do this from the root itself by naming your buttons movie clip as well. Lets say buttons_mc
so the code will now be....
buttons_mc.butt1.onRelease=function(){
_root.slides_mc.gotoAndPlay(1);
}
buttons_mc.butt2.onRelease=function(){
_root.slides_mc.gotoAndPlay(2);
}
buttons_mc.butt3.onRelease=function(){
_root.slides_mc.gotoAndPlay(3);
}
Hope this helps
Alan
sheepo-designs
04-02-2008, 06:13 PM
Thank you for your response, Alan
I think I should be a little more specific about my issue:
I am making a website for my portfolio and have run into a snag. I have a setup where there is a list of buttons (pages) that are spanning out from a content window. The content window is a MC (IllusCont) and the pages are, obviouslly, buttons I will be talking about just one (IllusSlide1). When the user clicks on "IllusSlide1" I have setup a test where the content window turns blue. However I am no able to find a way to make this happen. I have tried everyway I know possible, which is limited because I am only a novice at this.
I am using the code
this.onRelease = function() {
this.IllusCont.gotoAndPlay("blueMC");
}
which is used directly on "IllusSlide1". "blueMC" is simply a frame where the content box turns blue.
Does that make sense?
Thanks.