How to Add a Scroll Bar Component to Flash 8
Flash is the industry-standard program for creating animation and interactive Shockwave Flash (SWF) movies. Often, your Flash movie designs call for scrollable text boxes, or text boxes that allow your users to scroll through long blocks of text on the movie's stage. Adding a scroll bar component to create a scrollable text box in your Flash movies is easy. Flash 8's built-in UIScrollBar component lets you quickly define a text box as scrollable and automatically creates the scroll bar and scroll button controls---all with just a few simple mouse clicks.
Instructions
-
Making a Text Box Scrollable with UIScrollBar
-
1
Open the Flash FLA movie in which you want to create a scrollable text box. Click "File" on the menu bar and choose "Open." This displays the Open dialog box. Navigate to the FLA file, select it, and then click "Open."
-
2
Go to the frame and layer in the Timeline panel where you want to put the text box. (By default, the Timeline in Flash 8 is at the top of the document window.) Right-click the frame and choose "Insert Keyframe" from the fly-out menu.
-
-
3
Click the Text Tool (the "A" icon) to select it. Make sure you're still in the frame and layer where you want the text box, then draw a text box on the stage.
-
4
Go to the Properties panel (at the bottom of the document window), click the "Text type" drop-down (first option in the Properties panel) and choose "Dynamic Text." Click the "Line type" drop-down (third option from the top in the right pane of Properties) and select "Multiline."
-
5
Click the "Render text as HTML" button (second button to the right of the "Line type" drop-down). This tells Flash to display various text formatting, such as size, font, font weight, and so on, in the text box.
-
6
Click "Window" on the menu bar and choose "Components" to open the Components panel. Click "User Interface" to display the user interface component list. Drag UIScrollBar from the list to your text box. For example, to place the scroll bar on the right side of the box, drag the component to the right side, just inside the text box border and release the mouse button. The component snaps and attaches itself to the outside of the box on the right side.
-
7
Double-click inside the text box to place the text cursor. Type (or copy and paste from a text file) your text into the text box.
-
8
Test the movie to see the scrollable text box. Click "Control" on the menu bar and choose "Test Movie."
-
1
Tips & Warnings
Always apply the component to the text box before adding text. Otherwise, the text box will re-size to the length of the text block. You can change text formatting, such as font, size, color, and so on, from the options in the Properties panel. Select the text you want to format and make the desired changes in the panel.
UIScrollBar works the same in all versions of Flash.
If your movie loops repeatedly when you test it, place a "stop();" action (no quotes) in the Actions panel in the last frame of the movie. Right-click the last frame, choose "Actions" from the fly-out. Type the action in the right pane of the panel.
References
- Photo Credit computer mouse image by Sergey Danilov from Fotolia.com