Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How reset buttons between multi-movie framed window

Status
Not open for further replies.

wudz

Programmer
Mar 28, 2001
135
GB
here again, this flash is great..but a sod to get an old head round it..but I will plod on....the prob...
How can I reset the button state when I move from one movie to another in a multiframed window.If I use button 'b' on the right frame movie, then go to left frame and press say, 'd' button then return to right frame button 'b', it don't work because I can't find a way of carring over and resetting from the right framed movie or visa versa...clear as mud..hi.. can anyone help..
john
 
hi

You 'could' use Javascript and FScommands as discussed in previous threads. An explanation of how to do this can be found at:


Or on your Flash CD in the Goodies/Macromedia/Javascript_Demo folder.

Although this wouldn't do anything to control button states per se, if you changed your method it would work. ie: if you're button was transparent and you used an mc for the image with each frame representing a button state, you could use the above to control the mc, rather than the button. For example, you rollover the button and it tells the mc to go to frame2, you hit the button and it tells the mc to go to frame 3, etc.

Buttons in other HTML frames would use the Javascript/FScommand to control the 'button state' in other HTML frames by controlling the mc's rather than the buttons themselves.

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
Thanks again Dave, I will have a look at the link,hope this cures my prob...chatch you later..
John
 
John

Working on a more explanatory sample FLA for you at the minute. I'll post when I finish.

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
I've rustled up an example of how you use this to convert button states within other frames.

(15K)

As I said above, you're not actually changing the button state, rather you're tinkering with 2 movie-clips.

In the FLA you'll find one button and 2 mc's. The button holds all of the actions.

One mc (arranged to front) is simply the 'over' state of the button. On 'load' the alpha of this is set to zero. When you rollover the button the alph of this mc is set to 100, and when you rollout it is set back to zero again.

The other mc contains the 'down' and 'up' states.

When the user presses the button, the mc held within it's own movie is sent to the downstate frame (red). An FScommand is utilised to tell the mc in the other frame to go to the 'up-state' frame (orange).

I've put some instructions in the source code of the HTML as to where to place the Javascript involved, and which elements of syntax require alteration.

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
Dave, that is absolutely b----- magic, It works great..your some cool kid...I am knocking on a bit and the learning curve seems to be getting a bit to steep for me on the heavy bits, I keep thinking I am getting there, but it is the action script that gets me, I will keep trying though but love the Movie/ sound/ graphics capabilities that can be achieved for 56k, what a product...
thanks again Dave..you know yor biz............
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top