Creating a seperate database in VBA

  • Thread starter Thread starter Ryan
  • Start date Start date
R

Ryan

I was wondering if there was a way to create a seperate
database in VBA code. What I'm wanting to do is create
the database, then populate it with certain items using
the TransferDatabase method. Any suggestions are welcome.

Thanks,
Ryan
 
This can be done using the CreateDatabase (DAO) method. Check it out in
VBA Help for detailed information.
 
On my website, see sig below, is a small sample database that does just
that. Look for: "ImportToTempDatabase2k.mdb", which creates a temp
database, exports and empty table to it, relinks the table back to the main
database, then uses this temp table for importing data. This is done to
eliminate the bloat that can occur when data is imported to a native temp
table.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top