Hi Tim,
Thanks for you reply. Most probably its me (or the ref's) but I can't seem
to get anywhere. I would like to actually see the result of this query. I
did try quite a few stuff but still couldn't manage to get it displayed.
Once I am done with that, then I'll try and input that to a table.
Any further suggestions?
Alp
P.S.: If run within the db in question this does what I need (in basics that
is):
SELECT MSysObjects.Name, MSysObjects.DateCreate, MSysObjects.DateUpdate,
MSysObjects.Type, MSysObjects.Flags
FROM MSysObjects;
"Tim Ferguson" wrote in message
...
"Alp" wrote in :
I would like to query an mdb's/mde's MSysObjects from another
database. Sole purpose of this is to get the object names, creation &
update dates and what they are (types).
set db = ws.OpenDatabase(strPath, true, true)
Set rs = db.OpenRecordset( _
"SELECT Something, SomethingElse " & vbcrlf & _
"FROM MSysObject" & vbCrLf & _
"WHERE ObjectType = 409" & vbCrLf & _
"ORDER BY SomethingElse", _
dbOpenSnapshot, dbForwardOnly
With rs
.DoSomethingUseful
End With
I strongly suspect you will run into permission problems, but you can
always have a go. There probably is something in the square-bracket
syntax you could use:
SELECT Something, SomethingElse
FROM MySysObjects IN [Database=f:\someonesdata\someonesdb.mdb]
WHERE etc, etc
but I don't use that very often. Bear in mind that the structure of the
system tables is not documented and not guaranteed to remain the same in
subsequent versions of Access.
HTH
Tim F
|