Solved

Path from an ODBC Alias

Posted on 2000-04-04
3
277 Views
Last Modified: 2010-04-04
I want to get the path of my access database connected via ODBC into my application so that I can compact them.  Anyone help?
0
Comment
Question by:dvk
  • 3
3 Comments
 
LVL 2

Accepted Solution

by:
NetoMan earned 100 total points
ID: 2684477
You can get it from your registry windows file. There is some sample on how to get this information :

var
  AppRegistry: TRegistry;
  RegistryPath, FPath: string;

begin

  AppRegistry := TRegistry.Create;
  try
     RegistryPath := '\SOFTWARE\ODBC\ODBC.INI\accesdb';
    AppRegistry.OpenKey(Format('%s', [RegistryPath]),True);
    FPath := AppRegistry.ReadString('DBQ');
  finally
    AppRegistry.Free;
  end;
   

when accesdb is your ODBC Alias
0
 
LVL 2

Expert Comment

by:NetoMan
ID: 2684491
Check also if this path is correct but have to be for your ODBC Instances becuase is standard.

to check use regedit and look for it on HKEY_CURRENT_USER\SOFTWARE\ODBC\ODBC.INI\
0
 
LVL 2

Expert Comment

by:NetoMan
ID: 2687891
does it work ? I sure it Did....

I haved work whit this kind of operations...

If you need some more help...
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Suggested Solutions

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

746 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

8 Experts available now in Live!

Get 1:1 Help Now