EasyManua.ls Logo

MACROMEDIA FLASH MX 2004 - ACTIONSCRIPT - Page 707

MACROMEDIA FLASH MX 2004 - ACTIONSCRIPT
816 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
TextField.StyleSheet.parseCSS() 707
TextField.StyleSheet.onLoad
Availability
Flash Player 7.
Usage
styleSheet.onLoad = function (success) {}
Parameters
success
A Boolean value indicating whether the CSS file was successfully loaded.
Returns
Nothing.
Description
Callback handler; invoked when a TextField.StyleSheet.load() operation has completed. If the
style sheet loaded successfully, the
success parameter is true. If the document was not received,
or if an error occurred in receiving the response from the server, the
success parameter is false.
Example
The following example loads the CSS file named styles.css (not shown) into the style sheet object
styleObj. When the file has finished loading successfully, the style sheet object is applied to a
TextField object named
news_txt.
var styleObj = new TextField.StyleSheet();
styleObj.load("styles.css");
styleObj.onLoad = function (success) {
if(success) {
news_txt.styleSheet = styleObj;
}
}
See also
TextField.StyleSheet.load()
TextField.StyleSheet.parseCSS()
Availability
Flash Player 7.
Usage
styleSheet.parseCSS(cssText)
Parameters
cssText
The CSS text to parse (a string).
Returns
A Boolean value indicating if the text was parsed successfully (true) or not (false).

Table of Contents

Related product manuals