Hi, I have 3 movieclips on the main stage.
btn1, 2, 3
I have this code in the maintime line, that when i click a button, the btn the stays static (like its on), when i click another btn, it switches on the next button and loads an external swf.
Each button's instance name is button1, 2, 3..and more buttons I add the stage I would increase the button number, so for 3 buttons on stage I have up (var buttonNum:Number = 3
code//
var buttonNum:Number = 1;
for (i=1; i<=buttonNum; i++) {
this["button"+i].onRollOver = function() {
if (this.clicked != "yes") {
this.gotoAndPlay("over");
}
};
this["button"+i].onRollOut = function() {
if (this.clicked != "yes") {
this.gotoAndPlay("out");
}
};
this["button"+i].onRelease = function() {
this.gotoAndStop("out");
this._parent[_root.clickedButton].gotoAndPlay("out");
this._parent[_root.clickedButton].clicked = false;
this._parent[_root.clickedButton].enabled = true;
_root.clickedButton = this._name;
this.clicked = "yes";
this.enabled = false;
loadMovie ("myMovie.swf", _root.container);
};
}
This all works fine.
I have built a scroller with thumbnails as movieclips and would like to add this code to movieclips.
The thumbnails are indivdual moviclips and are inside a movieclip (productscroll), as the dragbar i am using targets the clip (productscroll) to scroll the thumbnails.
I basically need the same actions as the buttons. When I click a thumbnail I need to load an external swf.
Really appreciate any help on this.
I think its something to do with the path to the container.
Best
Sarah