Determine if DAO Jet engine version 3.5 is installed | CodeGuru

Determine if DAO Jet engine version 3.5 is installed

Sometimes it is useful to know if the computer running your software has the DAO Jet Engine version 3.5 installed. You need this engine when you work with MFC DAO objects. I needed to know if DAO 3.5 was there while writing my own setup program for a piece of work which used the CDaoXYZ […]

Written By
CodeGuru Staff
CodeGuru Staff
Mar 1, 1999
1 minute read
CodeGuru content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More

Sometimes it is useful to know if the computer running your software has the DAO Jet Engine version 3.5 installed.
You need this engine when you work with MFC DAO objects.

I needed to know if DAO 3.5 was there while writing my own setup program for a piece of work which used the
CDaoXYZ stuff, so I wrote a function that detects if the DAO Jet Engine is installed.

The trick used is to check if the the registry key HKEY_LOCAL_MACHINESoftwareMicrosoftJet3.5Engines
exists. If yes, then there’s at least one engine and the DAO Dll’s are installed.

You may use this code as implemented here (a function) or – if you don’t like the global functions – make it a
member function of your class needing the information.

In the header file for the function (or class) definition you need these definitions:

bool	DAO35Installed()
{
  HKEY hLM;

  bool ret=false;

  // let's open the Registry key for DAO 
  if (RegOpenKeyEx(HKEY_LOCAL_MACHINE,
    "Software\Microsoft\Jet\3.5\Engines",
    0,KEY_QUERY_VALUE, &hLM) == ERROR_SUCCESS)
  {
    ret = true;
    RegCloseKey(hLM);
  }

  return ret;
}

That’s it. If you need to insure that DAO is installed just test

if (!DAO35Installed())
  // warning here 
else
  // it's OK 

CodeGuru Logo

CodeGuru covers topics related to Microsoft-related software development, mobile development, database management, and web application programming. In addition to tutorials and how-tos that teach programmers how to code in Microsoft-related languages and frameworks like C# and .Net, we also publish articles on software development tools, the latest in developer news, and advice for project managers. Cloud services such as Microsoft Azure and database options including SQL Server and MSSQL are also frequently covered.

Property of TechnologyAdvice. © 2026 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.