Full List of All RunCommand Constants

Here is a complete list of RunCommand constants with a description of their function where I know what they do. Both the list in Access Help and the list obtainable on the Microsoft Web Site are incomplete and contradict one another.

I have colour coded the list dependent on the version in which they first appeared - Access 97, Access 2000, Access XP, Access 2003 or Access 2007. Prior to Access 2007, all later versions of Access recognise the earlier commands. See Known Problems for more details. Some of these were retained for backwards compatibility only. If you spot any errors or can fill the gaps please let me know.

Code Link links to code examples for that constant. Select the start letter, ignoring the acCmd, of the constant.

Select the sixth letter of the acCmdConstant
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Constants starting acCmdR

Constant
Description
Value

Code ExampleacCmdRecordsGoToFirst
Moves to the first record
67

Code ExampleacCmdRecordsGoToLast
Moves to the last record
68

Code ExampleacCmdRecordsGoToNew
Moves to a new record
28

Code ExampleacCmdRecordsGoToNext
Moves to the next record
65

Code ExampleacCmdRecordsGoToPrevious
Moves to the previous record
66

acCmdRecoverDesignMaster
Displays the Recover Design Master dialog
265

acCmdRedo
Redoes last thing that was undone
199

acCmdReferences
Displays the References dialog
260

Code ExampleacCmdRefresh
Refreshes the data in the active window
18

acCmdRefreshData
 
541

Code ExampleacCmdRefreshPage
Brandon Skeen tells me that he uses this command to refresh a sub form and all its fields behind an OnChange event
297

acCmdRefreshSharePointList
 
626

acCmdRegisterActiveXControls
Opens the ActiveX Controls dialog
254

Code ExampleacCmdRelationships
Opens the Relationships window
133

acCmdRemove
 
366

acCmdRemoveAllFilters
 
644

acCmdRemoveAllSorts
 
645

acCmdRemoveFilterFromCurrentColumn
 
643

Code ExampleacCmdRemoveFilterSort
Removes all filters and sorts
144

acCmdRemoveFromLayout
 
582

acCmdRemoveTable
Removes the selected table from the QBE grid
84

acCmdRename
Allows the editing of the name of the object selected in the database window
143

acCmdRenameColumn
Highlights column heading to enable renaming
274

acCmdRenameGroup
 
492

Code ExampleacCmdRepairDatabase
Opens the Repair Database file selection dialog box. Note this cannot be used to repair the current database
6

Code ExampleacCmdReplace
Opens the Replace dialog. Available in both VBE and non-VBE views
29

Code ExampleacCmdReportHdrFtr
Adds or removes report headers and footers
37

acCmdReportView
 
539

acCmdReset
Resets running code
124

acCmdResolveConflicts
Displays the Resolve Replication Conflicts dialog
266

acCmdRestore
 
514

acCmdRowHeight
Displays the Row Height dialog
116

Code ExampleacCmdRun
Runs a query
181

Code ExampleacCmdRunMacro
Opens the Run Macro dialog
31

acCmdRunOpenMacro
Run a macro
338