Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

deleting tables from VBA

Status
Not open for further replies.

JeroenNL

Programmer
Nov 28, 2002
217
NL
Hi there,

I want a routine that deletes all tables in my Access application. But I can't delete all of them, because some of the tables are systemtables of Access itself. I don't want a lot of IF name=??? statements here, I just want to delete my own tables. Anyone knows a solution for this?

Thanks,
Jeroen
 
Hi

Well all System Tables have names beginning MSys, so provided you have NOT named your tables beginning MSys, you could just loop through the tabledef collection, skipping those with name like MSys* and delete the rest. Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Thanks, that did the trick! Didn't know about the MSys thing. :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top