Database Objects in Codes?

04-15-2004, 05:17 AM
Hey Guys,

Please help me on this..

I'm having trouble creating a database using codes.. I'm currently using Microsoft DAO 3.6 Library..

Dim db As Database
Dim td As TableDef
Dim f(2) As Field
Private Sub Command1_Click()

Set db = DBEngine.Workspaces(0).CreateDatabase("C:\pedok.mdb", dbLangGeneral)

Set td = db.CreateTableDef("TableForm.ped")
End Sub

This code will create a database, my problem is I can't create a table for it, all the program do is create a blank database.
What should I do guys, please bare with me I'am a beginner in database programming.

Thanks in advance..

04-15-2004, 06:18 AM

Please have a look here:


EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum