ACC: Using Find Command in a Query Causes ErrorID: Q158926
|
Moderate: Requires basic macro, coding, and interoperability skills.
When you use the Find dialog box to search for a value in a query, you may
receive the following error message.
Note that this error only occurs when you display unique values in your query result, and the field you are searching with Find is sorted in Ascending order.In Microsoft Access 97
MSACCESS caused a stack fault in module MSJET35.DLLIn Microsoft Access 7.0
MSACCESS caused a stack fault in module MSJT3032.DLL
In Microsoft Access 2.0
MSACCESS caused a General Protection Fault in module MSACCESS.EXE
To work around the problem, create a form based on the query and use other
methods to search for specific records on your form.
The following example uses the sample database Northwind.mdb (or NWIND.MDB
in version 2.0) to demonstrate a method to find a record using a combo box
on a form:
Query: EmployeeZip
-------------------------------------------------
Type: Select Query
Field: Region
Table: Employees
Field: PostalCode (or Postal Code in version 2.0)
Table: Employees
Sort: Ascending
Macro Name Action
-----------------------------
FindZip GoToControl
FindRecord
Locate Product Actions
-------------------------------
GoToControl
Control Name: PostalCode
FindRecord
Find What: =[FindPostalCode]
Find First: Yes
Form: FindEmployeeZip
-----------------------------------
RecordSource: EmployeeZip
Caption: Find Employee Postal Codes
DefaultView: Single Form
Text Box
Name: Region
ControlSource: Region
Text Box
Name: PostalCode
ControlSource: PostalCode (or Postal Code in version 2.0)
Combo Box
Name: FindPostalCode
RowSource: EmployeeZip
ColumnCount: 2
ColumnWidths: 0";1"
BoundColumn: 2
AfterUpdate: FindZip
Microsoft has confirmed this to be a problem in Microsoft Access 2.0, 7.0 and 97.
Keywords : kberrmsg QryGnrl
Version : 2.0 7.0 97
Platform : WINDOWS
Issue type : kbbug
Last Reviewed: May 13, 1999