Textfield.maxscroll - MACROMEDIA FLASH MX 2004-ACTIONSCRIPT LANGUAGE Reference

Actionscript language reference
Table of Contents

Advertisement

TextField.maxscroll

Availability
Flash Player 6.
Usage
TextField.maxscroll:Number
Description
Read-only property; indicates the maximum value of TextField.scroll.
For more information on scrolling text, see "Creating scrolling text" in Using ActionScript in Flash.
Example
The following example sets the maximum value for the scrolling text field
buttons,
scrollUp_btn
ActionScript to your FLA or AS file.
this.createTextField("scroll_txt", this.getNextHighestDepth(), 10, 10, 160,
20);
this.createTextField("my_txt", this.getNextHighestDepth(), 10, 30, 320, 240);
my_txt.multiline = true;
my_txt.wordWrap = true;
for (var i = 0; i<10; i++) {
my_txt.text += "Lorem ipsum dolor sit amet, consectetuer adipiscing elit,
sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat
volutpat.";
}
scrollUp_btn.onRelease = function() {
my_txt.scroll--;
scroll_txt.text = my_txt.scroll+" of "+my_txt.maxscroll;
};
scrollDown_btn.onRelease = function() {
my_txt.scroll++;
scroll_txt.text = my_txt.scroll+" of "+my_txt.maxscroll;
};
896
Chapter 2: ActionScript Language Reference
and
scrollDown_btn,
to scroll the text field. Add the following
. Create two
my_txt

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MX 2004-ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash mx

Table of Contents