If you support more than one version of Access, you may often need to ask users which version is running before you can help them with a problem. Don’t have them guess! Create a button somewhere on their application form that, when clicked, will tell them exactly what version is running on their PC. Follow these steps:

  1. Open the form in Design view.
  2. Click the command button tool in the Form Controls toolbox. In Access 2007, click the Button form control in the Controls Group on the Forms Design tab.
  3. Click Cancel to close the Forms Control Wizard.
  4. Change the button caption to Which Version? (Figure A).

Figure A

  1. Right-click the button.
  2. Choose Build Event.
  3. Type the following code at the prompt (Figure B):
Private Sub Command6_Click()
Select Case SysCmd(acSysCmdAccessVer)
Case 7
MsgBox "This is Access 95", vbOKOnly
Case 8
MsgBox "This is Access 97", vbOKOnly
Case 9
MsgBox "This is Access 2000", vbOKOnly
Case 10
MsgBox "This is Access 2002", vbOKOnly
Case 11
MsgBox "This is Access 2003", vbOKOnly
Case 12
MsgBox "This is Access 2007", vbOKOnly
End Select
End Sub

Press [Alt] +[ Q].

Figure B

Now, users simply have to click the Which Version? button to let you know what version they are using (Figure C).

Figure C

Miss an Access tip?

Check out the Microsoft Access archive and catch up on other Access tips.

Help users increase productivity by automatically signing up for TechRepublic’s free Microsoft Office Suite newsletter, featuring Word, Excel, and Access tips, delivered each Wednesday.