Solved

Change extention of a database to my own application file.

Posted on 2009-07-09
3
182 Views
Last Modified: 2012-05-07
Dear experts,

I have made a programm that uses a MS-ACCESS database.
I use the components ADOConnection and ADOQuery for that.
And everythings works fine. But I have a couple of questions:

1. Do you have to install MSACCESS on the computer for my application
   to open an Acces-database?
2. I want to make of the database (.MDB) my own application file (.PKD)
    How can I do that?
3. If I change the database extention .MDB to a .PKD is than still possible
    to open it with MSACESS.

Greetings, Peter Kiers

 
0
Comment
Question by:peterkiers
[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
  • 2
3 Comments
 
LVL 6

Accepted Solution

by:
FactorB earned 500 total points
ID: 24812565
1. No, you don't need to. You just need the compatible driver, in your case "Microsoft.Jet.OLEDB.4.0" which is pre-installed on Windows XP and above, if not you can download it from http://support.microsoft.com/?id=239114

2. Simply change the file extension from Database.mdb to Database.pkd


3. It is not possible to open the .pkd file with access straight away, file association will be lost, you will need to redo the association with the help of open dialog or programmatically ...

3.5 :) In order to access your new database you will need to use appropriate connection string, ex.
Form1.ADOConnection1.ConnectionString:='Provider=Microsoft.Jet.OLEDB.4.0;Persist Security Info=False;Data Source='+IncludeTrailingPathDelimiter(ExtractFilePath(Application.ExeName))+'Database.pkd;';

Regards,
B.
0
 
LVL 1

Author Comment

by:peterkiers
ID: 24812920
Thanks for the info, you really helped me alot.
0
 
LVL 6

Expert Comment

by:FactorB
ID: 24813102
This was quick grading :)
You are always welcome.

Regards,
B.
0

Featured Post

Enroll in July's Course of the Month

July's Course of the Month is now available! Enroll to learn HTML5 and prepare for certification. It's free for Premium Members, Team Accounts, and Qualified Experts.

Question has a verified solution.

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

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Suggested Courses
Course of the Month4 days, 10 hours left to enroll

635 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