Stopping a mc with button

Hi can anyone help me I have made a movie clip and I have dragged it onto my main stage from the lib the mc is not on the main timeline
I have a button and when I press it I would like the mc to stop
I know very little about action script I have given an instance name to both button and mc.In the actions panel I work in normal mode how do I stop the mc when button is pressed
Thanks for your help stig

on (release) {
_root.yourmovie.stop();
}

put that in the button and that should work, just put the instance name of the movie where it says your movie :slight_smile:

Since your MC is not on the main timeline, you could use something like this:

[COLOR=royalblue]on (release) {
myMovieClip.mySecondClip.stop();
}[/COLOR]

…with the first movie having an instance name of myMovieClip and the other mySecondClip!

oops i didnt read that part about the main timeline…:-\ sorry

i tried cutting and pasting your reply (joso reply)
this is what i go back

Scene=Scene 1, Layer=text, Frame=1: Line 2: Expected a field name after ‘.’ operator.
_root.eq.stop();

the eq bit is my mc i dont have a layer for it i just drag it from lib

did you put the code in the button? are the button and MC in the frame or is the button in the MC?

Yes I put code in button button has its own layer on main t.line frame 1
Mc has no layer on main t.line made mc (new symbol then made mc then dragged it from lib) I think I have got this all wrong (lol)

i have made other buttons on same layer
that work they links to other pages using action s all ok there

Don’t use eq as a movie clip name, because Flash thinks you are referring to “=”, eg,

if (password eq “dude”).

(lol ) ok thanks for that and thanks to the others too
stig

yes it worked thanks again to all