creating a scroll bar
Copy link to clipboard
Copied
Ok what I have is a site I am building for school. I have some textfields loaded from a outside file. Some of the fields have more text then will show in the size of the box, and you can sroll it down to read it all but unless you try to scroll there is really now way to tell you can do it just buy looking at the text box. So I want to add a scroll bar and we have not covered that in class.
Note everything has to be added using AS3 we can have no content on the timeline. I have look to try to find something so show me how to dod this but all I can find are videos on doing it using the stage and adding items to it.
Copy link to clipboard
Copied
any scrollbar tutorial that uses an on-screen scrollbar can be used to suit your needs. just assign the scrollbar a class and use the new constructor to create the scrollbar and use addChild to add the scrollbar to your display.
Copy link to clipboard
Copied
Can you make it a little more plane please. I am working on so much other sruff along with this I am drawing a blank. I tried a couple things but get this arroa code.
TypeError: Error #1034: Type Coercion failed: cannot convert fl.containers::ScrollPane@311540b1 to flash.display.MovieClip.
at flash.display::Sprite/constructChildren()
at flash.display::Sprite()
at flash.display::MovieClip()
at beta_fla::MainTimeline()
Copy link to clipboard
Copied
a scrollpane is a flash component used to display images.
a scrollbar is used to display hidden text in a textfield.
from your description you want to use a scrollbar, not a scrollpane. there's no as3 scrollbar component that comes standard in flash. you need to make your own or download someone else's.
Copy link to clipboard
Copied
ok thanks i will see what i can find
Copy link to clipboard
Copied
You can use the UIScrollbar component with a textField in Flash. If your textFields are on the stage then just drag an instance of the UIScrollbar onto the textField.
Copy link to clipboard
Copied
I am loading them from an external file. Can I still use it and if so where do I find it, I did not see it in the component box.
Copy link to clipboard
Copied
in the user interface folder in the components panel, it's the last component in that folder.

