I have a piece of code that works from within a database to get the Access Version of that database. What I am trying to do is create an inventory of Access databases and their versions so I would like to modify the code to work from another database instead of the current db. If possible it would be great if it could loop through a directory and output the Access Versions of each mdb it comes across.
Here is the code I have so far. I am not sure if this function supports having a string to another database.
Public Function getDefaultFileFormat() As Long
On Error GoTo ErrHandler
getDefaultFileFormat = GetOption("Default File Format")
Exit Function
ErrHandler:
MsgBox "Error in getDefaultFileFormat( )." & vbCrLf & vbCrLf & _
"Error #" & Err.Number & vbCrLf & vbCrLf & Err.Description
Err.Clear
'The function will return 8 for Access 97 file format, 9 for Access 2000 file format, or 10 for Access 2002 - 2003 file format.
End Function
Here is the code I have so far. I am not sure if this function supports having a string to another database.
Public Function getDefaultFileFormat() As Long
On Error GoTo ErrHandler
getDefaultFileFormat = GetOption("Default File Format")
Exit Function
ErrHandler:
MsgBox "Error in getDefaultFileFormat( )." & vbCrLf & vbCrLf & _
"Error #" & Err.Number & vbCrLf & vbCrLf & Err.Description
Err.Clear
'The function will return 8 for Access 97 file format, 9 for Access 2000 file format, or 10 for Access 2002 - 2003 file format.
End Function