Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Database Design / June 2004

Tip: Looking for answers? Try searching our database.

Date mdb was created

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Steven - 20 Jun 2004 05:35 GMT
Is there a way to return when a mdb file was created?

Like CurrentDb.Name will return the Name of the file.

What is the command the will return the date and time the
file was created?

Thank you,

Steven
Jay Vinton - 20 Jun 2004 17:45 GMT
> Is there a way to return when a mdb file was created?

Hi Steven,

To get the create/modify info for the MDB, click Tools -> References and add a reference to the Microsoft Scripting Runtime. Then:

Dim fso As Scripting.FileSystemObject
Dim fil As Scripting.File

Set fso = New Scripting.FileSystemObject
Set fil = fso.GetFile(CurrentDB.Name)

Debug.Print fil.DateCreated, fil.DateLastAccessed, fil.DateLastModified

Set fil = Nothing
Set fso = Nothing

To get similar info on tables

Debug.Print CurrentDB.TableDefs("tablename").DateCreated (and .LastModified)

Jay
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.