Flash CS6 transparent button link Creation

Source: Internet
Author: User
Preparation of Hyperlink buttons for as2.0 and as3.0 and common languages

=====As2======================================

1. Create a new layer in the Flash layer. Here we name it "transparent button ". Use a rectangle tool to draw a rectangle of the same size as the flash image.

2. Select the drawn rectangle and press F8 to convert it into a key component. Here we will give a name.

3. Set the transparency of the button component to 0%.

4. Select the transparent button and right-click the action (or press F9) to enter the action panel:

Write the following code into the panel:

On (release ){
Geturl ("http://www.2lengzi.com", "_ blank ")
}

The test is complete.

=====As3======================================

1. Create a new layer in the Flash layer. Here we name it "transparent button ". Use a rectangle tool to draw a rectangle of the same size as the flash image. And convert it to button components.

2. Select the named button and give it an Instance name. For example, we name it star_btn"

3. Create a new layer, name it as, and press F9 to open the action panel. Write the following code in the Action panel:

Star_btn.addeventlistener (mouseevent. Click, starurl );
Function starurl (E: mouseevent): void
{
VaR request: URLRequest = new URLRequest ("http://www.2lengzi.com /");
NavigatetoURL (request );

}

The test is complete.

Common statements:

Transfer to next frame

First, you name the button instance on the stage, such as BT, and then write the code on the timeline: Stop (); BT. addeventlistener (mouseevent. click, bthd); function bthd (E: mouseevent) {This. nextframe ();}

Flash CS6 transparent button link Creation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.