MSQUERY: Application Error With Microsoft Access ODBC Driver

Last reviewed: September 13, 1996
Article ID: Q149773
The information in this article applies to:
  • Microsoft Query for Windows, version 1.0
  • Microsoft Query for Windows 95, version 2.0
  • Microsoft Excel for Windows, versions 5.0, 5.0c
  • Microsoft Excel for Windows 95, versions 7.0, 7.0a

SYMPTOMS

If you use DDERequest to retrieve a list of tables from a Microsoft Access database, you may receive one of the following error messages, depending on which version of Microsoft Excel and Microsoft Query you are using:

Microsoft Excel version 5.0 or 5.0c and Microsoft Query version 1.0

   MSQUERY caused a general protection fault in module MSQUERY.EXE
   at 0017:00003537

Microsoft Excel version 7.0 and 7.0a and Microsoft Query version 2.0

   MSQRY32 caused an invalid page fault in module MSQRY32.EXE
   at 0137:0047e661

CAUSE

You may experience this behavior, if the following is true:

  • You are using the DDE request statement:

          <Table Array> = DDERequest(<Channel>, _
          "Tables/<DataSourceName>/<User>/<Database>)"
    

    Where <Table Array> is the name of the variable assigned to hold the returned value, <Channel> is the DDE to Microsoft Query channel variable, <DataSourceName> is the specified Data Source Name, <User> is the specified User Name, and <Database> is the specified Database Name.

    -and-

  • If at least one of the following is true:

        - You are using the Microsoft Access 2.0 ODBC Driver from the ODBC 2.0
          Driver Kit, the ODBC 3.0 Driver Kit, or the ODBC Drivers supplied
          with Microsoft Access 7.0.
    

          -or-
    

        - You are using the Microsoft Access 7.0 ODBC Driver from the ODBC 3.0
          Driver Kit or the ODBC Drivers supplied with Microsoft Access 7.0.
    

WORKAROUND

You can avoid the error symptoms by leaving the User argument blank. The Table data will be returned based upon the currently connected User:

   <Table Array> DDERequest(<Channel>, _
      "Tables/<DataSourceName>//<Database>"

where <Table Array> is the name of the variable assigned to hold the returned value, <Channel> is the DDE to Microsoft Query channel variable, <DataSourceName> is the specified Data Source Name, and <Database> is the specified Database Name.

If you use a Table Array variable of TableArray, a Data Source Name of "Access 7.0 NWind", and a Database Name (location) of C:\Msoffice\Access\Samples\Northwind, then the DDERequest statement would look similar to the following:

   TableArray = DDERequest("Access 7.0 NWind"// _
      & "C:\MSOFFICE\ACCESS\SAMPLES\NORTHWIND")

REFERENCES

For additional information about the syntax of this DDERequest statement, see the "Microsoft Query 1.0 User's Guide," Chapter 9, "Using Dynamic Data Exchange with Microsoft Query."


KBCategory: kbtool kberrmsg
KBSubcategory: xlquery

Additional reference words: XL5 XL7 5.00 5.00a 5.00c 7.00 7.00a




THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: September 13, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.