Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Detecting DAO and it's version

Posted on 2002-05-15
3
267 Views
Last Modified: 2008-03-04
Let me start off by telling you what I'm trying to do.  I'm writing a component checker to detect if a component is installed and what it's version is.  I'm detecting things like ADO, DTS, DMO, and DAO.  I'm trying to do this with out setting any project references, so yes I'm using late binding.  Please save the lecture of the evils of late binding, I already know.  This program is not doing much other than provide me with a users system info, to try and make my life easier when the call up complaining that something doesn't work because they didn't read the release notes and didn't follow instructions about installing components.  I digress...

The one that's giving me the biggest problem is DAO.  The following is an example piece of code:
    Dim lTemp    
    Set lTemp = CreateObject("DAO.Recordset")

All the other have not given me any problem.  I really don't want to go looking for files on their hard drive either.

Any have an idea on how to detect DAO and report it's version using a late binding method?

Steve
0
Comment
Question by:Steve Sirica
3 Comments
 
LVL 6

Expert Comment

by:pierrecampe
ID: 7012646
if DAO is installed then there is a registry key for it
for 3.5 it is:
HKEY_CLASSES_ROOT\DAOEngine.35
for 3.6 it is:
HKEY_CLASSES_ROOT\DAOEngine.36

0
 
LVL 14

Accepted Solution

by:
Matti earned 50 total points
ID: 7012753
Hi!

I have here one latebinding sample.

http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=29536&lngWId=1

Those very old versions seems to not support latebinding, they are not creatable!

Matti
0
 
LVL 4

Author Comment

by:Steve Sirica
ID: 7013556
That's what I was looking for.  
I was using:
    createobject("dao.dbengine")
when I should hev been using:
    createobject("dao.dbengine.36")
     or
    createobject("dao.dbengine.35")

Thanks for your help
Steve
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

856 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