Here are a few VBScript that hopefully get a version for you. Save this in a plain text file with the vbs extension and drag mdb onto it. This is a very quick sketch and only roughly checked.
Set fs = CreateObject("Scripting.FileSystemObject")
If WScript.Arguments.Count > 0 Then
sPath = WScript.Arguments.Item(0)
Else
sPathTemp = Left(WScript.ScriptFullname, _
InStrRev(WScript.ScriptFullname, "\"))
sPath = InputBox("Enter Path and Name of .mdb", "Get Ver", sPathTemp)
End If
If sPath = "" Or fs.FileExists(sPath) = False _
Or Right(sPath, 4) <> ".mdb" Then
MsgBox "Not a valid file: " & vbCrLf & sPath, 64, "Get Ver"
Else
Set cnnDB = CreateObject("ADODB.Connection")
cnnDB.Provider = "Microsoft.Jet.OLEDB.4.0"
cnnDB.Mode = 1 ''adModeRead
On Error Resume Next
cnnDB.Open sPath
If Err.Number <> 0 Then
MsgBox "Error"
Else
MsgBox "4 = Access 97, 5 = Access 2000 (2002?)" & vbcrlf & _
"Value for " & sPath & " is: " & _
cnnDB.Properties.Item("Jet OLEDB:Engine Type").Value
cnnDB.Close
End If
End If
source
share