M
Mike Mertes
I was wondering if someone could give me some information about programming
for Microsoft Data Access Objects. Namely, I've noticed that when I open a
database via 'DBEngine.Workspaces(0).OpenDatabase(Path)', if I enumerate the
tables that are automatically appended to the TableDefs collection (For Each
TblDef in Database.TableDefs : debug.print TblDef.Name : Next TblDef) I get
unexpected results. '?TableDef(0).Name' has an expected result: The name of
the first table in my MSAccess database. Also in accordance with
expectation, the results for ?TableDef(1, 2, 3, and 4) follow suit. Here is
the unusual part: Naturally I assume the next Table in the TableDefs
collection will be the next successive table in my database, but it's not.
Instead I get these Tables:
TableDef(5).Name = MSysAccessObjects
TableDef(6).Name = MSysACEs
TableDef(7).Name = MSysObjects
TableDef(8).Name = MSysQueries
TableDef(9).Name = MSysRelationships
follwed by TableDef(10 & 11), the last two tables in my database.
Why are these [access object collections?] represented as Tables in the
TableDefs collection, and why do they appear right in the middle of the list
(effectively splitting it into halves, and being an annoyance!) ...and, are
there any properties that dictate this behavior?
Thanks again,
-Mike
for Microsoft Data Access Objects. Namely, I've noticed that when I open a
database via 'DBEngine.Workspaces(0).OpenDatabase(Path)', if I enumerate the
tables that are automatically appended to the TableDefs collection (For Each
TblDef in Database.TableDefs : debug.print TblDef.Name : Next TblDef) I get
unexpected results. '?TableDef(0).Name' has an expected result: The name of
the first table in my MSAccess database. Also in accordance with
expectation, the results for ?TableDef(1, 2, 3, and 4) follow suit. Here is
the unusual part: Naturally I assume the next Table in the TableDefs
collection will be the next successive table in my database, but it's not.
Instead I get these Tables:
TableDef(5).Name = MSysAccessObjects
TableDef(6).Name = MSysACEs
TableDef(7).Name = MSysObjects
TableDef(8).Name = MSysQueries
TableDef(9).Name = MSysRelationships
follwed by TableDef(10 & 11), the last two tables in my database.
Why are these [access object collections?] represented as Tables in the
TableDefs collection, and why do they appear right in the middle of the list
(effectively splitting it into halves, and being an annoyance!) ...and, are
there any properties that dictate this behavior?
Thanks again,
-Mike
