pulling table modified date

T

Ted

hey all, i'm trying to set the value of a text box on my form to the Created
Date of a table in my database. its not the recordsource of the form. any
ideas?

TIA
Ted
 
A

Allen Browne

You could get the creation date of the table if you OpenDatabase on the back
end, and look at the DateCreated property of the TableDef:
OpenDatabase("C:\MyFolder\MyDB.mdb").TableDefs("MyTable").DateCreated

Unfortunately, Access 2000 and onwards doesn't maintain these dates
correctly for all objects, so test it thoroughly.
 
T

Ted

Thank you Allen, I tried code similar and also tried yours and i keep
getting "Invalid use of property". It doesn't like the DateCreated Property.
any ideas?
 
T

Ted

ummmm one more thing...i have a link to the table in my db. i tried using
the dlookup function but it gives me the date created of the link

DLookup("DateCreate", "MSysObjects", "Name =
'L:\TVB\DIGINV\DIGINV.MDB\ALLCOMPANIESDATA'")
 
A

Allen Browne

Take it a step at a time.

Try:
OpenDatabase("C:\MyFolder\MyDB.mdb").Name

Then:
OpenDatabase("C:\MyFolder\MyDB.mdb").TableDefs("MyTable").Name
and so on.
 
T

Ted

Thx Allen...i tried that but still got "Invalid use of property"
is there a reference that i'm missing?
 

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

Top