Exercises Unit 12: Buttons

Exercise 1: To Create a Button in form of Pill

1 Open File → New

2 To draw the pill shape first draw a circle. Select the tool Paint Bucket and select gradient from white to blue, placing the markers as it is shown at the right and apply it as fill.

   Once this is done, draw two parallel lines in the center of the circle. Separate both semicircles. Delete the lines and widen the rectangle that was within them until touching the semicircles.

a)     b)       c)   d)   e)

3 Select Insert → New Symbol... or press F8

4 Create keyframes in all the frames using F6 and modify them to create the effect

5 File → Save As... and call it stop.


Exercise 2: Adjusting the Active Area


1 Make this also with File → New

2 Use the Text Tool marked in the Toolbar with one A and write text: Let's gO.

3 Use the Insert → New Symbol...or or press F8

4 Select the frame Hit Area, draw an oval in such a way that it completely covers the "O" and has the same size and shape. Then delete the rest of the text.


Exercise 3: Button with Sound


1 Open File → New.

2 Select the frame Up and access Window → Library; drag one of the sounds to the scene, if you don't have it, import it from your hard disk...

3 Select the frame Down and access Window → Library; drag one of the sounds to the stage, if there is; when you don't have any stage, import it from your hard disk...


Exercise 4: Stopping a Movie 


1 Open File → New

2 Create an animated movie clip or import one as we've seen in the previous unit. Keep it on the desktop.

3 We double click over the inserted clip to edit it, add a new layer, and in the first frame of this layer we'll insert the button. For this we access File → Import → Open External Library and we select "stop.fla" to open the library from the file. After it, we drag the button to the stage.

4 We right click the button and chose the option Actions or directly open Actions Panel and select the button. On the left side of the Actions Panel we double click Actions → Timeline Control, (if they were not already open) and then we double click the action Stop. The code will be displayed as:

on(release) {




Legal warning: Authorised on-line use only. It is not allowed the use of these courses in companies or private teaching centres.
© aulaClic. All rights reserved. Reproduction in any form whatsoever is prohibited.