Solved

hide/show layer useing action script?

Posted on 2004-08-08
1
1,706 Views
Last Modified: 2011-10-03
I am adding actionscript to a button so that it has hide and show functionality. I have found a solution on EE that says

http://www.experts-exchange.com/Web/WebDevSoftware/Flash/Q_20809360.html

I just need to clarify some things.

When you create the instance of the movie you want to appear do you place it on the main timeline or on the button timeline. Also I want the clip to appear on mouseover and to stay there until someone clicks another link, then the effect which was for button 1 should stop and the same effect should happen for button 2. please HELP
0
Comment
Question by:fusionless
1 Comment
 
LVL 9

Accepted Solution

by:
dutchfoxer earned 500 total points
ID: 11749458
Okay, you will have 2 buttons, one "show layer" and one "hide layer". (or something similar)

You will also have a movieclip that you give a name once put on the main timeline ("wheel1" as in example).

The 2 buttons and movieclip you put on the main-timeline.

"show layer" button will have the action script:

on(rollOver){
    _root.wheel._visible = true;
}

"hide layer" button will have the action script:
on(rollOver){
    _root.wheel._visible = false;
}

And what about "wheel1" when the flash-movie is first started? Shown or hidden? If you want it hidden when movie starts then create a new layer and call it actions. On the first blank-keyframe you put the following action script:
_root.wheel._visible = false;
stop();

on(rollOver)   can also be   on(release) for mouseclicking.


Good luck! Hope it is a bit more clear!?

0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
Recently, I was asked to recommend a tracking system to be implemented on a clients website. As the entire site was built on flash, my first thought was to suggest custom built tracking system. However, our company at that point of time didn't h…
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question