Solved

ODBC & ADO installation

Posted on 2000-04-12
6
327 Views
Last Modified: 2010-04-10
Hi!

What is the safest/ most reliant way to find out if ODBC 3.5, ADO and Access Driver is installed on a computer?
I know that if I install MDAC I will get all that, but they could be there without MDAC installed and I don't want to install MDAC if I don't have to.
So, which are the keys I should read i registry to find out these three things?
(There are so many ODBC-things in the registry I don't know which one I should rely on.)
Thanks!
0
Comment
Question by:Scattan
[X]
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
  • 3
  • 3
6 Comments
 
LVL 1

Accepted Solution

by:
Assafgo earned 30 total points
ID: 2708671
First, it doesn't hurt to install MDAC, it actually fixed bugs in odbc 3.7 for SQL Server in my case.
Second, all the information you need can be viewed easily from Control Panel->Odbc Data Sources.
There you can find which Odbc drivers are installed, which versions, and what dll's are they using.
All administration can be done from there.
0
 

Author Comment

by:Scattan
ID: 2709044
Thank you Assafgo, but I'm writing an installation program and cannot go to the control panel etc. to see which installations the computer that the program will be installed on has, I need to do it programmatically.
That's why I don't want to install MDAC if I don't have to, or promt the user to do it if the installation program cannot find the required software.
So do you have any tips on which registry keys I can check for instead?

Thanks!
0
 
LVL 1

Expert Comment

by:Assafgo
ID: 2710804
In this case - simple.
The installed odbc drivers are written in the odbcinst.ini in the windows folder.
If you want to get their versions (it's not there, only the names), then go to the registry for
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers
and there you can find what's installed.
under each subkey of HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI you may also find the details (version, etc..)
Good luck
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Scattan
ID: 2710899
Thanks!

And what about ADO?
0
 
LVL 1

Expert Comment

by:Assafgo
ID: 2711194
ADO is actually an ActiveX component.
To find if it exists, you can use programming methods (QueryInterface...)
The problem is that there are many interfaces to ADO, as you can see in the registry keys under
HKEY_CLASSES_ROOT such as
HKEY_CLASSES_ROOT\ADOConnectObject.ADOConnectObject and anything else that starts with the name ADO.

another way I think will suffice is to check that the file Msadodc.ocx exists
(and you can know the version that way also)
0
 

Author Comment

by:Scattan
ID: 2711298
OK, thats not the best answer, but its good enough, thank you!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

691 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