Solved

Accessing fields in a .mdb file without opening MSAccess window application.

Posted on 1998-08-17
2
247 Views
Last Modified: 2011-04-14
How can I open a .mdb(MSAccess) file and get to the individual field entries in my c++ program. What is the name of the Access DLL where the functions are located. My goal is to use the Access DLL without opening the MSAccess window application to get at the information in the .mdb file. I want to be able to get at each record and gather the data from every field in the records. Also, where is the API list of functions for the Access DLL published.
0
Comment
Question by:kns2
2 Comments
 
LVL 1

Accepted Solution

by:
JayMerritt earned 50 total points
Comment Utility
The term you are looking for is DAO - Data Access Objects.

These are located in:
  \Program Files\Common Files\Microsoft Shared\DAO

Look at the DAO35.hlp for more.

Visual Basic has a lot of documentation on how to get the database schema for an MDB file.
0
 
LVL 1

Expert Comment

by:rlarner
Comment Utility
Are you _SURE_ you want to do this?  I assume you are not using MS C++ libraries -- otherwise you should be using either the DAO classes or the ODBC classes (e.g. CDaoTableDef will allow you to find out all the fields for a given table in DAO.  You must do something a little more complex for the non-DAO version -- MSDEV 5.0 comes with an example called CATALOG which implements a class that will give you the desired information.)  So far, I have prefered DAO -- it seems to be a more complete implementation.

If you are NOT using MFC, then the name of the dll that you want actually depends on the version of access you want to use.  I can give you a pointer, however -- MS Access is built using something called the Jet database engine.  On my system, I have msjet35.dll, which is what Access 97 uses.  (95 should have msjet30.dll, and 2.0 has msjet20.dll I believe.  I'm not too sure about the last one)  For the API, I am not to sure where to find exact documentation.  I don't actually recommend this solution -- from what little I have seen of the API from stepping through DAO objects, it is not a very pretty interface.
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Today's users almost expect this to happen in all search boxes. After all, if their favourite search engine juggles with tens of thousand keywords while they type, and suggests matching phrases on the fly, why shouldn't they expect the same from you…
In the article entitled Working with Objects – Part 1 (http://www.experts-exchange.com/Microsoft/Development/MS_Access/A_4942-Working-with-Objects-Part-1.html), you learned the basics of working with objects, properties, methods, and events. In Work…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now