Libre
been around a little
- Local time
- Yesterday, 22:41
- Joined
- May 3, 2007
- Messages
- 660
Hi - I'm new here, and I hope you don't mind if I jump right in with a question.
Suppose I want to delete a table, programatically. I could write:
DoCmd.DeleteObject acTable, "myTable"
Now, that would work, unless the table was related to another table, and then I would get this error-
Run Time Error '2387':
You can't delete the table 'myTable'; it is participating in one or more relationships.
Can anyone tell me how to delete the relationship, programatically, before executing the delete table command?
In fact, what I REALLY want to do is to delete ALL the relationships, and then ALL the tables in the entire db.
And of course, I want to do it all programatically, not by selecting the objects and hitting the delete key.
Any help would be greatly apprecitated. Thanks in advance.
Suppose I want to delete a table, programatically. I could write:
DoCmd.DeleteObject acTable, "myTable"
Now, that would work, unless the table was related to another table, and then I would get this error-
Run Time Error '2387':
You can't delete the table 'myTable'; it is participating in one or more relationships.
Can anyone tell me how to delete the relationship, programatically, before executing the delete table command?
In fact, what I REALLY want to do is to delete ALL the relationships, and then ALL the tables in the entire db.
And of course, I want to do it all programatically, not by selecting the objects and hitting the delete key.
Any help would be greatly apprecitated. Thanks in advance.