Errata for ActionScript for Flash MX: The Definitive Guide

The errata list is a list of errors and their corrections that were found after the product was released. If the error was corrected in a later version or reprint the date of the correction will be displayed in the column titled "Date Corrected".

The following errata were submitted by our customers and approved as valid errors by the author or editor.

Page xxiv
last bullet point in the section entitled Chapter 13 Movie Clips

* Removed the quiz example, which is superceded by...
NOW READS:
* Removed the quiz example, which is superseded by...
page 34, Example 1-4, the second comment;
// Create an onscreen text field do display the user's score.
NOW READS:
// Create an onscreen text field to display the user's score.
page 210, last line of the second code sample;
initFormFields(editFields, highlightField);
NOW READS:
initFormFields(editFields, handleFieldFocus);
page 243 Example 10-2, immediately before the example;
The following HAS BEEN ADDED:
"The box_mc clip must be square, and must have an initial size between box_mc.maxHeight and box_mc.minHeight."
NOTE: For the curious, here's a version of the example that does not
impose those limitations (though the added complexity distracts from the example's real
focus, event handlers):
// Set oscillation parameters.
box_mc.scaleIncrement = 10;
box_mc.maxHeight = 200;
box_mc.minHeight = 20;
// Start the box off at the maximum size.
var heightRatio = box_mc._height / box_mc.maxHeight;
box_mc._xscale /= heightRatio;
box_mc._yscale /= heightRatio;
// Adjust the scale increment to match the new size.
box_mc.scaleIncrement /= heightRatio;
// Resize the box with each passing frame.
box_mc.onEnterFrame = function () {
if (this._height >= this.maxHeight
|| this._height <= this.minHeight) {
this.scaleIncrement = -this.scaleIncrement;
}
this._xscale += this.scaleIncrement;
this._yscale += this.scaleIncrement;
}
page 622 IN PRINT:
The entire "Mouse.removeListener() Method" entry
HAS BEEN MOVED so that it appears before:
the "Mouse.show() Method" entry
page 625 IN PRINT: In Table R-12, the "Method description" for "loadMovie()";
"Loads an external .swf file into the Player."
NOW READS:
"Loads an external .swf or .jpg file into the Player."
page 627 In Table R-14, the asterisk next to onLoad() HAS BEEN REMOVED (in accordance with the erratum for page 684).
page 628 IN PRINT: In Table R-14;
"onMouseMove() Primary mouse button is depressed and then released while the clip is on stage"
and
"onMouseUp() Mouse pointer moves (even a teensy bit) while the clip is on stage"
NOW READ:
"onMouseMove() Mouse pointer moves (even a teensy bit) while the clip is on stage"
and
"onMouseUp() Primary mouse button is depressed and then released while the clip is on stage"
page 650
In the description for MovieClip._droptarget, the following sentence:
"A movie clip is considered to be 'over' another clip if the registration point of the dragged clip overlaps any portion of the target clip."
NOW READS:
"A movie clip is considered to be 'over' another clip if the mouse pointer overlaps any portion of the target clip."
page 684 IN PRINT: Second sentence at the top of the page:
"It does not apply to main movies (e.g., _root, _level1, etc.)."
NOW READS:
"For main movies, onLoad() works only when assigned on frame one of the movie loaded onto _level0 in the Flash Player."
page 819 IN PRINT: second to last prose paragraph on this page, the final two sentences of the paragraph:
"Unfortunately, at the time of writing, a bug prevents this proxy-movie system from working in the current build of Flash Player 6 (6.0.61.0). Macromedia is aware of the issue and is working to address it."
NOW READS:
"Unfortunately, in releases of Flash Player 6 prior to version 6.0.47.0, a bug prevents this proxy-movie system from working. Source files demonstrating the technique are available at: http://www.moock.org/asdg/technotes/crossDomainLoad."

trace("pi is: " + PI); // Displays: 3.1459... (PI is property of Math)
NOW READS:
trace("pi is: " + PI); // Displays: 3.14159... (PI is property of Math)
page 164 IN PRINT: The third line of the last code sample on the page:
trace("x is less than 5");
NOW READS:
trace("i is less than 5");
page 165 IN PRINT: The third line of the first code sample on the page:
trace("x is less than 5");
NOW READS:
trace("i is less than 5");
page 173 IN PRINT: In line 5 of example 8-3:
if (form[prop].text == "") {
NOW READS:
if (form_mc[prop].text == "") {
page 193 The last code block on the page:
NOW READS:
_global.functionName = function () {
statements
};
page 210 IN PRINT: The last line of the second code sample:
initFormFields(editFields, highlightField);
NOW READS:
initFormFields(editFields, handleFieldFocus);
page 225 IN PRINT: The last sentence of the second prose paragraph under "Listener Events":
"Because State.onResize() is a listener event..."
NOW READS:
"Because Stage.onResize() is a listener event..."
page 227 IN PRINT: In the first paragraph after the warning note, in the second sentence:
"allowing for a entire movie's layout"
NOW READS:
"allowing for an entire movie's layout"
page 244 IN PRINT: Line 20 of Example 10-4:
// Turn the clip bright red when the mouse is off of it
NOW READS:
// Turn the clip dark red when the mouse is off of it
page 259 IN PRINT: In line 16 of Example 11-3:
months.splice(5, 2, "june");
NOW READS:
months.splice(5, 2, "June");
page 284 IN PRINT: In the first paragraph following the warning note,
in the list of properties between em dashes:
"yPostion"
NOW READS:
"yPosition"
page 288 IN PRINT: The number in last line of the only code sample on the page:
78.5398163397448.
NOW READS:
785398.163397448
page 302
The third line of the third code sample on the page NOW READS:
importantDates.gwenBirthday = "January 17";
not:
var importantDates.gwenBirthday = "January 17";
page 333 IN PRINT: In the second sentence of the tip note:
"...or myClip in the movie clip hierarchy..."
NOW READS:
"...or theClip in the movie clip hierarchy..."
page 387 IN PRINT: In the code example following the heading "MovieClip Sub-Subclasses":
Line 3 of the code, which reads:
// ... init code ...
HAS BEEN MOVED after line 5, and NOW READS:
super()
// ... init code ...
page 548 IN PRINT: Under -Infinity's "Description" heading, in the last sentence:
"an underflow condition"
NOW READS:
"a negative overflow condition".
page 593 IN PRINT: Under "See Also";
"Security.settings.allowDomain()"
NOW READS:
"System.security.allowDomain()".
page 631 IN PRINT: Under "Description", in the third code block on the page:
tBall_mc._xscale = 200;
NOW READS:
tBall._xscale = 200;
page 671 IN PRINT: The synopsis for "loadMovie()":
"Load an external .swf file into the Player."
NOW READS:
"Load an external .swf or .jpg file into the Player."
page 694 IN PRINT: Under MovieClip._rotation's Example heading, the second line of the code sample:
box_mc.onEnterFrame = function {
NOW READS:
box_mc.onEnterFrame = function () {
page 704 IN PRINT: Under the first See Also on the page:
"System.Security.allowDomain()"
NOW READS:
"System.security.allowDomain()"
page 710 IN PRINT: Under MovieClip._ymouse's Example heading, the first line of the code sample:
onEnterFrame = function () {
NOW READS:
this.onEnterFrame = function () {
page 708 The last sentence of the Description heading for MovieClip._xmouse:
NOW READS:
"To obtain a consistent _xmouse coordinate that is always measured relative to the Stage of the base
movie in the Player, use _level0._xmouse."
page 710 The last sentence of the Description heading for MovieClip._ymouse:
NOW READS:
"To obtain a consistent _ymouse coordinate that is always measured relative to the Stage of the base
movie in the Player, use _level0._ymouse."
page 725 IN PRINT: Under "Usage" for "Object.__proto__ Property". The first 5 words:
"Overwriting an object's constructor property"
NOW READS:
"Overwriting an object's __proto__ property"
page 804 IN PRINT: in the warning note for #strict:
"...Flash Player 6.0.61.0..."
NOW READS:
"...Flash Player 6.0.65.0..."
page 924 IN PRINT: The synopsis for XML.contentType:
xmlDoc.contentTypeAccess
NOW READS:
xmlDoc.contentType
page 969 The entry for "Macromedia Flash file format":
NOW READS:
"Here you can obtain the SWF specification, which 'documents the Macromedia Flash file format (SWF),
and how to write Macromedia Flash 6 (SWF) files.'."
page 980 IN PRINT: In the heading "Updates to Flash Player 6, Build 61":
NOW READS:
"Build 65"
page 980 IN PRINT: The first sentence that follows the "Updates" heading:
"...Macromedia released Build 61 of Flash Player 6 (Flash Player 6.0.61.0)."
NOW READS:
"...Macromedia released Build 65 of Flash Player 6 (Flash Player 6.0.65.0)."
page 1016 IN PRINT: Under the term "HEIGHT", the end of the sentence:
"of the HTML page width in the browser."
NOW READS:
"of the HTML page height in the browser."

If (this._x != leaderX && this_y != leaderY) {
NOW READS:
If (this._x != leaderX || this_y != leaderY) {
page 348 IN PRINT: The code example immediately following the second bulleted paragraph:
this.duplicateMovieClip("newClouds_mc", 0);
NOW READS:
if (this._name != "newClouds_mc") {
this.duplicateMovieClip("newClouds_mc", 0);
}
page 525 In Table R-6, under "exec," the second and third sentences;
"In Flash MX, the application must reside in a folder named "fscommand"
directly beneath the .swf file (if a .swf file resides in
/demo/, the application to launch must reside in /demo/fscommand/). For
example, to launch someApp.exe, use "fscommand("exec", "someApp.exe")",
without the subfolder name /fscommand/."
NOW READ:
"In Flash MX, the application must reside in a folder named "fscommand"
directly beneath the Flash Projector file (if a Projector file resides in
/demo/, the application to launch must reside in /demo/fscommand/). For
example, to launch someApp.exe, use "fscommand("exec", "someApp.exe")",
without the subfolder name /fscommand/.
page 990 IN PRINT: The last table row on the page, left hand column, entry heading, "Object constructor":
"Object constructor"
NOW READS:
"Object Constructor
(Flash 5 only)"

Anonymous

Dec 01, 2004

Printed

Page 516

The Date.setUTCFullYear() method is listed as having only a year parameter. In actual fact,
it also has month and day parameters that function exactly like the parameters of the same
name defined by Date.setFullYear().