Excel 2002 Power Programming With VBA


Return to The Spreadsheet Page

Excel 2002 Power Programming With VBA

Errata

Ideally, I would like every book that I write to be completely accurate and error-free. The fast-paced nature of the computer book publishing industry makes this goal difficult to achieve. However, I assume complete responsibility for the content of my books.

Listed below are known errors in my Excel 2002 Power Programming With VBA book. If you discover additional errors, please let me know.


  • General:
    You'll find word wrap problems in many of the code examples in this book. Apparently, the production department is not trained to identify bad line breaks in VBA code listings. Hopefully, these errors will not cause any problems. When in doubt, consult the example files on the CD-ROM.
  • Front Cover:
    The publisher's web site address is no longer valid. If you need to contact the publisher, use www.wiley.com.
  • Page 36:
    The first paragraph in the "Compatibility" section lists Excel 2000 twice. the sentence should read: For example, Excel 97, Excel 2000 and Excel 2002 all use the same file format...
  • Page 37:
    The first bullet point specifies "X" as the multiplication operator. It should be an asterisk (*).
  • Page 38:
    The "New Feature" box at the top of the page refers to Excel 2000. It should actually refer to Excel 2002.
  • Page 39:
    A production error caused the formula to get mangled. It should be:

    =C$3*$B4
  • Page 42:
    In the "Using Links to Recover Data in a Corrupt File" sidebar, the formula listed should be:

    ='C:\Files\[BadFile.xls]Sheet1'!A1
  • Page 44:
    At the bottom of the page, the formula returns 440, not 183.
  • Page 45:
    In the "Naming columns and rows" section, the references in the first paragraph do not match Figure 3-2. They are off by one column.
  • Page 46:
    The formula in the "Naming Constants" section should be:

    =RATE*A3
  • Page 49:
    Another mangled formula. It should be:

    =A1:A5*B1:B5
  • Page 53:
    In Table 3-3, rows 7 and 8 use "x" as a wildcard character. The "x" should be an asterisk (*).
  • Page 54:
    In Table 3-4, all of the "x" characters should be asterisks (*).
  • Page 178:
    The first two words on the page, End Sub, are actually part of the code listing from the previous page.
  • Page 182:
    There's a production formatting error in Table 8-1. In the Boolean row, True or False should be in the third column.
  • Page 186:
    In the second bullet point, the word Explicit is spelled incorrectly. 
  • Page 246:
    The first paragraph below the code listing refers to Text.xls. The filename should be Test.xls.
  •  Page 251:
    In the "Tip", the statement should be Option Compare Text (not Option Text Compare)
  • Page 251:
    In the second-to-last block of code, Sub is shown as SubOp. The statement should be:

    If ActiveWorkbook Is Nothing Then Exit Sub
  • Page 269 and 271:
    In the Commission and Commission2 function listings, the second Case statement should be:

    Case 10000 To 19999.99
     
  • Page 275:
    The last bullet point on this page may be confusing. Keep in mind that the AllNames array is zero-based, and indices range from 0-11. In the statement that uses the Mod operator, 1 is subtracted from the function's argument. Therefore, an argument of 13 returns 0 (corresponding to "Jan"), and an argument of 24 returns 11 (corresponding to "Dec")
  • Page 306:
    The definition provided for "Union" is actually the definition for "Intersection."
  • Page 310:
    In the "Transferring one-dimensional arrays" section, the range reference should be in quotes: Range("A1:A100").Value...
  • Page 320:
    The code to list all fonts will fail if there is no active workbook.
  •  Page 324:
    When using the FileSearch object, it's a good idea to use the NewSearch method to clear any previous search criteria. In Listing 11-8, the code should be:

    With FS
        .NewSearch
        .LookIn = FilePath

     
  • Page 332:
    The last formula listed on the page has mismatched parentheses. It should be:

    =(COUNTIF(A1:A100,">=10")) - (COUNTIF(A1:A100,">20"))
  •  Page 345:
    The API function declaration is omitted from the listing for GetExecutable (it is correct on the CD-ROM). The function declaration is:

    Private Declare Function FindExecutableA Lib "shell32.dll" _
    (ByVal lpFile As String, ByVal lpDirectory As String, _
    ByVal lpResult As String) As Long
  • Page 365:
    The data type for FileName should be Variant. This is because it could possibly be False (if the dialog box is canceled).
  •  Page 620:
    The SendAMessage example at the bottom of the page was supposed to be deleted. This procedure was not tested and may or may not work correctly. This example is not on the CD-ROM.
  • Page 621:
    The TestKeys procedure at the bottom of the page was supposed to be deleted. 
  • Page 710:
    The statement at the top of the page is displayed with a bad line break. It should be on a single line.
  • Page 726:
    The last paragraph refers to code "which follows." That code is not listed in the book. Refer to the file on the CD-ROM.
  •  Page 779:
    The text incorrectly states that the Print # statement uses a Tab character to separate the values. In fact, it uses spaces.
  • Page 834:
    In the last paragraph, the text should read, The following statement creates an array that consists of three variants.
  • Page 872:
    The Err function returns the error number (not the error message).
  • Page 876:
    The Weekday function is listed twice.

### End of known errors ###