Detecting Vista

P

PC User

I finally figured it out. I'm posting this for other who can use it.
=====================================
Public Function AccessVersion()
Dim objRetVal As Integer
Set objAccess = CreateObject("Access.Application")
objRetVal = objAccess.SysCmd(acSysCmdAccessVer)

Select Case objRetVal
Case "8.0"
AccessVersion = "97"
Case "9.0"
AccessVersion = "2000"
Case "10.0"
AccessVersion = "2002"
Case "11.0"
AccessVersion = "2003"
Case "12.0"
AccessVersion = "2007"
End Select
Set objAccess = Nothing

End Function
=====================================
 

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