Creating an MS Access database from ADO?

I need to CREATE from scratch an MS Access database with tables and fields all from scratch using ADO... Where do I start?


Using DAO I knew how to do it but can't seem to figure it out in ADO.


Why? Why? Why? everyone asks why would I do this... The program will collect data but I don't want to send out a database in the install and some tables won't be needed for some users. This way only what is needed by the user will be created at the time they need it.
gwizAsked:
Who is Participating?
 
Éric MoreauConnect With a Mentor Senior .Net ConsultantCommented:
0
 
schworakCommented:
Is there no way to do it with standard ADO 2.5?
0
 
Éric MoreauSenior .Net ConsultantCommented:
No you need ADOX.
0
 
Éric MoreauSenior .Net ConsultantCommented:
You can create new tables using the "CREATE TABLE" syntax using the Execute method of your ADO connection object but the database itself must be created using ADOX.
0
 
Ryan ChongCommented:
Here are some other examples:

Create a Database, Tables, Columns and Indexes Using ADOX
http://www.freevbcode.com/ShowCode.Asp?ID=3315

Create an Access 2000 Database Using ADOX
http://www.freevbcode.com/ShowCode.Asp?ID=803
0
All Courses

From novice to tech pro — start learning today.