Learn how to create a button of three states and send to address URL
1. To create a Button, first do this.
a)-. Create a new document (Ctrl. + J), size: 150 * 80 pixeles.
b)-. Background color #FFFFFF.
2. Create a new symbol (Ctrl. + F8).
a)-. Name it button and select the option: TypeButton.
3. Draw a rectangle the way you want, in the first frame (Up).
a)-. Color #0000FF.
b)-. Size: 100.0 * 20.0 pixeles.
c)-. Put in coordinated X = 0.0 y Y = 0.0.
4. Add a text with the word BUTTON.
a)-. Place in coordinated X = 0.0 y Y = 0.0.
5. Insert a keyframe (F6) in the frame (Over) in the timeline.
a)-. Modify the color of filler of the rectangle.
6. Insert a keyframe (F6) in the frame (Down) in the timeline.
a)-. Modify the color of the rectangle again.
7. Now return to scene.
a)-. Click on the symbol (button) in the Library window, and drag it to the scene. Press Ctrl + Enter to see the three states of the button in operation.
8. Now add an address URL to direct the button toward a webpage in specific.
a)-. Select the button of the scene and then to open the panel of Actions and to write the following code. Well done!
on (press) {
getURL("http://www.onlyphotoshop.com", "_blank");
}
Press Ctrl. + Enter and see the final result. Make click on the button and surprise.
See you very soon.