Page 1 of 1

creating Access Database

PostPosted: February 2nd, 2007, 9:43 pm
by Kapilshah
hey guys

please help me out with this one. I am trying to create an Access datadase using Delphi. I found this set of instructions :

1. Select Project | Import Type Library
2. Choose "Microsoft ADO Ext 2.x for DDL and Security (Version 2.x)"
3a. Change "TTable" to "TADOXTable"
3b. Change "TColumn" to "TADOXColumn"
3c. Change "TIndex" to "TADOXIndex"
3d. Change "TKey" to "TADOXKey"
3e. Change "TGroup" to "TADOXGroup"
3f. Change "TUser" to "TADOXUser"
3g. Change "TCatalog" to "TADOXCatalog"
4. Press Install button (rebuilding packages)
5. Press OK once and Yes twice
6. File | Close All | Yes

I went to Components, and selected the Import Components, and then selected Import Type Library, after which i selected as mentioned in the 2nd step but then it does not let me change the names ... and it also doesnt have an install button. Please tell me whether i did the correct thing, and acccording to instructions this procedure will install 7 new components, but the way I do it nothing gets installed. please do help me out here. I am using Borland Delphi 2005.
if any other way to create a database do let me know.

Thank you,

PostPosted: February 2nd, 2007, 9:57 pm
by Kambiz
This procedure is for Delphi versions prior to 2005.

I think you have to write the component wrappers by yourself.

Try this

PostPosted: February 4th, 2007, 10:54 pm
by eashton
I have used these components in the past and found them to be very good.

http://www.kadao.dir.bg/

PostPosted: February 5th, 2007, 6:38 am
by sepehr
wow,so amazing i was about to post the same problem! 8)
i'm using delphi 2005 and i wonder if there is a way to create an access database without the use of MS Access

i exactly have done what Kapilshah has done and have the same problem

PostPosted: February 5th, 2007, 5:22 pm
by Kapilshah
hey
so eashton can you help us, how to go along. When i followed the steps, it did not install the 7 components but it did create an ADOX_TBL.pas unit as stated in the procedure.
The next thing in the procedure it stated to create an empty form and add ADOXCatalog(Active X page) on the form, but since the components were not installed, i could not add them on the form. So if you could help me in context with Borland 2005, or if there some other way of creating then let me know. Thanks for you comments. Hope it will also help me and our other friend who has also posted the same problem.

Needs more information..

PostPosted: February 5th, 2007, 10:45 pm
by eashton
Gentlemen,

It looks like you are trying to create your own type libraries. The link in my previous post does not require you to do this. Just download the component (KAADO 1.0), ensure that you have MSDAC 2.7 installed on the computer, open the kaado.dpk file and compile/install.

It is as simple as that. No need to fiddle with type libraries.

PostPosted: February 6th, 2007, 6:10 am
by sepehr
i followed instructions that comes with KADO as follows:
1. Open KA.Data.KADao.dpk
2. If it is a Delphi 2005 select "Delphi for .NET"
3. In the Project Manajer window right click on KA.Data.KADao.dll and select "Build"
4. Create subdirectory called "Source" in the KADao folder and move there all .pas files
5. Select Component/Installed Net Components menu
6. Select ".Net VCL Components" Tab
7. Click on "Add" button
8. Navigate to the KADao Folder
9. Select KA.Data.KADao.dll and click "Open" button
10.When Open Dialog closes click on "OK" button

but the component is not added tp my pallete
ps:i have MSDAC 2.7 installed

Cannot help you from here...

PostPosted: February 6th, 2007, 9:40 pm
by eashton
..as I am on D6. The only other thing that I can suggest is that you contact the developer of the component. His email address is on the website.

Best of luck
Elliot

PostPosted: February 16th, 2007, 4:17 pm
by MrBaseball34
In D6, you can create a .mdb file if you import the ADOX type
library and use code like this.

Code: Select all
uses ...,ADOX;

var
  ADOXCataolog:TCatalog;
begin
  ADOXCataolog:=TCatalog(nil);
  try
    ADOXCatalog.Create1('Provider=Microsoft.Jet.OLEDB.4.0;Data Source=new.mdb');
  finally
    ADOXCataolog.free;
  end;
end;


or follow one of these tutorials:
http://codecentral.borland.com/codecent ... g?id=15292

http://delphi.about.com/library/weekly/aa072401a.htm