Writing Excel Macros

Errata for Writing Excel Macros

Submit your own errata for this product.


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.

Color Key: Serious Technical Mistake Minor Technical Mistake Language or formatting error Typo Question Note Update



Version Location Description Submitted By Date Submitted Date Corrected
Printed
Page xix
The following information was added to the preface under

the "How to Contact Us" section: "You can also send messages electronically. To be put on our mailing list or to request a catalog, send email to: info@oreilly.com To ask technical questions or comment on the book, send email to: bookquestions@oreilly.com We have a web site for the book, where we'll list examples, errata, and any plans for future editions. You can access this page at: http://www.oreilly.com/catalog/9781565925878/ For more information about this book and others, see the O'Reilly web site: http://www.oreilly.com"

Anonymous    Feb 01, 2000
Printed
Page 50

The first block of code used to read: "ActiveSheet.Range("A1").Font.Bold = True" It now reads: "ActiveSheet.Range("A1")._ Font.Bold = True"

Anonymous    Nov 01, 1999
Printed
Page 50
The first block of code and the sentence before it used to

read: For example, the following code is treated as one line by Excel: ActiveSheet.Range("A1")._ Font.Bold = True" Now reads: For example, the following code ActiveSheet.Range("A1").Font.Bold = _ True is treated as one line by Excel.

Anonymous    Feb 01, 2000
Printed
Page 51
The following sentence was added as the second sentence in

the paragraph following the "Enums" heading: "A list of enums can be obtained using my Object Model Browser software."

Anonymous    Feb 01, 2000
Printed
Page 61

The third set of code used to read: "For i = 1 to 100 Cell(i).Font.Bold = True Next i" It now reads: "For i = 1 To 100 Set cell(i) = Cells(i, i) ' cell(i) now points to i-th cell on the diagonal of active sheet cell(i).Font.Bold = True Next"

Anonymous    Nov 01, 1999
Printed
Page 61
About 1/3 of the way down the page, the third block of code

and the sentence before it used to read: For instance, the following code boldfaces the values in each of the 100 cells in the array: For i = 1 To 100 Set cell(i) = Cells(i, i) ' cell(i) now points to i-th cell on the diagonal of active sheet cell(i).Font.Bold = True Next Now reads: For instance, the following code boldfaces the values in each of the 100 cells along the diagonal of the active worksheet: For i = 1 To 100 Set Cell(i)=Cells(i,i) Cell(i).Font.Bold = True Next i

Anonymous    Feb 01, 2000
Printed
Page 118

The second B head on the page used to read: "Global Objects" Now reads: "Global Members" There are global members, but there is also only one global object. This section should be about global members, not global objects.

Anonymous    Feb 01, 2000
Printed
Page 133

The first line of the third bulleted item used to read: "even" It now reads: "event"

Anonymous    Nov 01, 1999
Printed
Page 135
In the second line beginning with "Dim" of Example 10-2, one line

is now "cbcpop" instead of two lines with "cbpop" getting defined. The second "Dim" line used to read: "Dim cpop As CommandBarControl" It now reads: "Dim cbcpop As CommandBarControl"

Anonymous    Nov 01, 1999
Printed
Page 135-136
In Example 10-2, the code at the bottom of page 135 had

a single, rather trivial error. Namely, in the first declaration: Dim cbpop As CommandBarControl the variable "cbpop" should be changed to "cbcpop". However, the entire code has been simplified by using only one variable. All of the code of Example 10-2 on pages 135-136 has been replaced with the following code: Sub CreateCustomMenuItem() Dim cbcpop As CommandBarControl ' Check for custom menu. If it exists then exit. Set cbcpop = Application.CommandBars( _ "Worksheet menu bar"). _ FindControl(Type:=msoControlPopup, _ Tag:="SRXUtilsCustomMenu") If Not cbcpop Is Nothing Then Exit Sub ' Control does not exist -- create it. Set cbcpop = Application.CommandBars( _ "Worksheet menu bar"). _ Controls.Add(Type:=msoControlPopup, _ Temporary:=True) cbcpop.Caption = "Cu&stom" ' Set tag property to find it later for deletion cbcpop.Tag = "SRXUtilsCustomMenu" ' Add menu item to popup menu With cbcpop.Controls.Add(Type:=msoControlButton, _ Temporary:=True) .Caption = "&ActivateSheet" .OnAction = "ActivateSheet" End With End Sub

Anonymous    Feb 01, 2000
Printed
Page 136

Point 2 in "Final Steps" used to read: "...as shown in Figures 10-4 and 10-6, making..." This should reference Figures 10-6 and 10-8. Now reads: "...as shown in Figure 10-6 and Figure 10-8, making..."

Anonymous    Feb 01, 2000
Printed
Page 149
In the middle of the page, 16 lines from the bottom, the

reference to "Application.Workbook" has been changed to "Application.CommandBars".

Anonymous    Feb 01, 2000
Printed
Page 154
In Example 12-3, the fourth line from the bottom of the page used

to read: "Print #fr, ctl.Caption & " (" & ctl.Id & ")"" It now reads: "Print #fr, ctl.Caption & " " & ctl.Id"

Anonymous    Nov 01, 1999
Printed
Page 155-156
In the middle of the page below Example 12-5, the contents

of Figure 12-3 were incorrect. On page 155 in the bottom paragraph below the Example "Creating a Menu," the text says: "The program shown in Example 12-5 creates the menu system shown in Figure 12-3 on Excel's worksheet menu bar." Unfortunately Figure 12-3 on page 156 did not relate to the cited example code in Example 12-5. The real Figure 12-3 has been replaced by Figure 12-5 from page 160. The correct figure is the same as Figure 21-2 from "Writing Word Macros." That figure has been used to replace the incorrect Figure 12-3 in this book.

Anonymous    Feb 01, 2000
Printed
Page 211

In the first line of text, the phrase "set of any" now reads: "set to any".

Anonymous    Feb 01, 2000
Printed
Page 407
The author forgot to remove the temporary code in Lines 5-8

of Example 21-2. It used to reads: ' Temporary If ActiveSheet.ChartObjects.Count > 0 Then ActiveSheet.ChartObjects(1).Delete End If This removes the chart if it already exists. (I used this temporary code while developing the example.) This code has been removed from Example 21-2.

Anonymous    Feb 01, 2000
Printed
Page 519-532
A new index was added in this printing, replacing the

index of previous printings.

Anonymous    Feb 01, 2000
Printed
Page 531
On the colophon page in the "About the Author" section, it

previously referred to one of Steven Roman's books as "Learning Word Programming." This titled has been changed to "Writing Word Macros."

Anonymous    Feb 01, 2000
Printed
Page 531
On the colophon page in the "About the Author" section, the

second to last sentence previously read: "He is currently working on a book entitled Win32 API Programming with Visual Basic to be published by O'Reilly." This book is now in print. The sentence now reads: "He has recently completed a book entitled Win32 API Programming with Visual Basic published by O'Reilly."

Anonymous    Feb 01, 2000