Access 2000 Developer's Handbook
Volume I, Desktop Edition
Last updated 19 November 2001.
Chapter
|
Page |
Where |
Replace |
With |
|
Inside back cover |
|
Book prices |
Prices on
books are incorrect. For example, the two Access 2000 Developer's Handbooks are listed
at $54.99, where as the book the reader just bought cost them $59.99. Oops! |
|
|
Frontmatter |
Page xiiii |
|
Replace all
use of word "Appendicies" with "Appendices" or
"Appendixes" (either one is acceptable, "Appendicies" is not). This
one, unfortunately, broke after leaving our final edits. |
|
| 2 (Added 3/21/2001) |
frmEventTest. |
Private Sub lboDessert_Click() |
Private Sub lboDessert_Click() |
|
|
3 (Added 2/1/2000) |
69 |
First code example |
TfOpenReadOnly, TfOpenReadWrite |
tfOpenReadOnly, tfOpenReadWrite |
|
3 |
75 |
First code example |
For wksEach in ActiveWorkbook.Worksheets |
For Each wks In ActiveWorkbook.Worksheets |
|
5 |
126 |
First paragraph, second sentence |
This form is
totally self-contained and thus will work without any changes if you import it into any
other database. |
To use the
form in another database, import the frmSQLScratchpad form plus the ControlResize,
FormResize, and SectionResize class modules. |
|
5 |
139 |
Figure 5.7 caption |
you can
include the CEO, Mary Jones, even though she has no supervisor. |
you can
include the CEO, Peter Jones, even though he has no supervisor. |
|
5 |
169 |
Code immediately above the head "External ISAM Databases" |
In " d:\a2kdh" |
In "d:\a2kdh" |
| 5 |
194 |
SQL statement immediately preceding the Cascading Referential Integrity head |
WHERE ItemId = tblOrder1.Itemid |
WHERE ItemId = tblNewOrder1.ItemId |
| 6 (Added 3/27/2001) | 222 | Last code snippet on the page | rst.Open "tblCustomers", cn | rst.Open "tblCustomers", cnn |
| 6 (Added 1/10/2000) | 255 | Second block of code | rst.Connection = CurrentProject.Connection | Set rst.ActiveConnection = CurrentProject.Connection |
|
6 |
270 |
Final line of the page |
rst.PercentPosition |
rst.AbsolutePosition |
|
6 |
276 |
Listing 6.14 |
Entire
listing, and remove WARNING on page 278. Unfortunately, interactions between ADO and
Access seem to have changed since this chapter was written. ADOX is not required for
this purpose. |
Public Sub DemoParameters() ' Done without using ADOX Dim cmd As ADODB.Command Dim rst As ADODB.Recordset Dim prm As ADODB.Parameter ' Before running this procedure,
open ' frmInfo and enter a value, like
"Berlin", ' into the City text box, then tab off
' of
the text box. ' You must move the focus out of the
' City
text box in order for this to work. Set cmd = New ADODB.Command Set cmd.ActiveConnection =
CurrentProject.Connection cmd.CommandText = "qryCustCity" ' If you use adCmdStoredProc,
' this
won't work. cmd.CommandType = adCmdTable ' This next statement is actually
optional. ' If you leave it out, ADO does it
anyway. cmd.Parameters.Refresh ' Loop through the parameters For Each prm In cmd.Parameters prm.Value =
Eval(prm.Name) Next prm ' And populate the recordset Set rst = cmd.Execute Do Until rst.EOF Debug.Print
rst.Fields(0).Value rst.MoveNext Loop rst.Close Set rst = Nothing Set cmd = Nothing End
Sub |
|
6 |
279 |
Table 6.10, 6th row, first column |
adSeekAfterEq |
adSeekLastEq |
|
6 |
279 |
First paragraph, first sentence |
If your index
includes multiple columns, you must supply all the values in an array, which you can
construct with the VBA Array function. |
If you want to
seek using an index that includes multiple columns, you can seek on just the first
column using a single value. To seek on multiple columns, supply the values as an array
(perhaps using the Array function to create the array). |
|
6 (Added 9/16/2000) |
281 |
Last paragraph, first line |
Just as with the Find method, you must follow every call to a Find method with a check of the recordset's EOF property | Just as with the Seek method, you must follow every call to a Find method with a check of the recordset's EOF property |
|
7 |
390 |
Listing 7.4, first procedure |
Private
Function IsLoaded(strName As String, _ As
Boolean |
Private
Function IsLoaded(strName As String, _ As
Boolean |
|
7 (added 2/16/2001) |
403 |
Table 7.4, 3rd row |
acLGGetColumnCount |
acLBGetColumnCount |
|
|
422 |
2nd bullet point on the page, first line |
the field you
display must can |
the field you
display can |
|
7 (added 1/27/2000) |
TaggedValues class |
This class behaves badly if you pass it a set of values that end in a semi-colon (or don't otherwise conform to the requirements of the class. Oops! Please download TaggedValues.cls and place it into any project that uses this code (and there are several in the book that do). |
||
|
7 (added 5/11/2000) |
TaggedValues class |
Remove
the extraneous procedure, Private Sub ParseItems. Set mcolItems = Nothing |
|
|
|
7 (added 8/28/2001) |
TaggedValues class |
The previous erratum was incorrect. Instead of Set mcolItems = Nothing |
Add the following line of code at the beginning of the Property Let Text procedure: Set mcolItems = New Collection |
|
|
7 (added 8/30/2000) |
|
SpinButtons class |
Code in HandleKeys method: Select Case KeyAscii |
This replacement code: Select Case KeyAscii |
|
8 (Added 3/29/01) |
529 |
Final paragraph |
Figure 8.11 shows formatting applied to the Order Date text box. |
Figure 8.11 shows formatting applied to the Quantity text box. |
|
8 (Added 3/29/01) |
529 |
Figure 8.11 caption |
Here, specific order dates are displayed in red text and underlined. |
Here, specific quantities are displayed in red text and underlined. |
|
8 |
560 |
The example may fail if you add a row to the first subform, and then immediately start adding rows in the second subform. Because code hasn't run to update the linking text box, the rows in the second subform will be orphaned. One easy fix is to call the Form_Current event procedure from the Form_AfterInsert event procedure, like this, forcing the text box to update as soon as you insert the new row: Private Sub Form_AfterInsert() Call Form_Current End Sub |
||
| 8 (added 5/30/2000) |
601 | Final code sample |
fi.RestoreCoords adhcAppName |
fi.RetrieveCoords adhcAppName |
| 8 (added 8/6/2000) | 609 | 4th and 5th paragraphs | Two occurrences of "WM_SYSMENU" | WS_CAPTION |
| 8
(added 12/14/1999) |
If your form contains controls that have negative offsets, the form resizing code can go into an infinite loop. I can't see how to make this happen (Access 2000 won't allow you to place controls at a negative offset), but one reader came across it. To fix the problem, open the FormResize class module, find the GetControlInfo procedure, and locate the line: .Name = ctl.Name Immediately below that line, add these two lines of code: If
ctl.Top < 0 Then ctl.Top = 0 |
|||
|
8 (added
11/19/2001) |
If you have floating
controls and "Show window contents while dragging" is turned on in
Windows, if you squish a form too small, you'll get into an infinite loop.
In FormResize.ScaleFormContents, replace this code:
If FloatThisControl(ctlr) Then |
With this code:
If FloatThisControl(ctlr) Then |
||
9 (added 1/19/2001) |
652 |
Table 9.1, last row |
9-25 |
9-24 (Note: Reports provide 25 sections, numbered 0 through 24.) |
|
9 |
692 |
Entire section |
The code doesn't quite work as advertised. See the Downloads page on this site to download Ch09Update.ZIP. |
|
| 9 (added 3/13/2000) |
693 |
Code sample | Still
another small code error: if you press the Cancel button on the popup form, you leave a
dangling reference and Access won't close. Replace this line with the code in the next
column:
Cancel = msl.Cancel (This code was updated in the Ch09Update.ZIP sample file on 3/13/2000) |
If
msl.Cancel Then |
|
9 (added 1/23/2000) |
708 |
Accumulating Sales... section |
The reference to the sidebar about the Useful NZ function |
(Nothing -- the sidebar was removed, but the reference wasn't.) |
|
9 |
709 |
Third paragraph, first sentence |
to keep track of whether the current row will be printed. |
to keep track of which color to use for printing the current row. |