Keyboard Shortcuts

Visual FoxPro supports keyboard shortcuts in these areas:

  • Browse window
  • Class Browser
  • Code window
  • Controls
  • Editor
  • Form and Class Designer
  • Help
  • Menu commands
  • Print Preview window
  • Properties window
  • Report and Label Designer
  • Window manipulation

Browse Window

Shortcut Action
CTRL+HOME Moves to first record of a cursor or table in a grid and when using the BROWSE command.
CTRL+END Moves to the last record of a cursor or table in a grid and when using the BROWSE command.

Class Browser

Shortcut Action
F5 Refreshes the current view.
SHIFT+F10 Displays a shortcut menu.
Right-click+Open button
Right-click+Add button
Right-click+Component Gallery button
Displays a history of last 32 files loaded.
Right-click+View Class Code button Displays the class code in a webview form.
CTRL+Right-click+Class icon
(in upper left corner of the Class Browser)
Creates an instance of the class with the NEWOBJECT( ) function in the Command window.

Identical to dragging the Class icon onto the Command window.

SHIFT+Right-click+Class icon
(in upper left corner of the Class Browser)
For forms, runs the form.

For other controls and objects, creates an instance of the control or object. For controls, also adds the control to the Visual FoxPro desktop at 0,0.

Identical to dragging the Class icon onto the Visual FoxPro desktop.

Code Window

Shortcut Action
ALT+I Presses the View Parent Code button.

Controls

Shortcut Action
CTRL+TAB When a Grid control has focus, exits the grid.

When an EditBox control has focus, and EditBoxAllowTabs property is True (.T.), exits the edit box.

When inside a form or dialog box containing a PageFrame control, moves to the next page in the page frame. However, this behavior is not supported in project files or when the page frame contains an ActiveX control.

CTRL+SHIFT+TAB If inside a form or dialog box containing a PageFrame control, moves to the previous page in the page frame. However, this behavior is not supported in project files or when the page frame contains an ActiveX control.
TAB When a Grid control has focus, moves to the next field.

Editor

To edit windows in Visual FoxPro, you can use modifier keys to choose either cut-and-paste or copy-and-paste dragging.

In Visual FoxPro, you can change the default drag-and-drop behavior by selecting the option, Drag drop between words, in the Editor tab in the Options dialog box. You can see the Editor tab by selecting Options from the Tools menu and choosing the Editor tab. Use ALT+Drag to toggle to the alternate setting (drag to within words or drag between words only).

Shortcut Action
ALT+Drag (previous Visual FoxPro default) Cuts and pastes.
CTRL+Drag Copies and pastes.
CTRL+I Show IntelliSense information.
CTRL+J Show members or list values using IntelliSense.
F2 Moves to the line containing the next bookmark.
SHIFT+F2 Moves to the line containing the previous bookmark.
ALT+SHIFT+F2 Toggles a bookmark for the current line on and off.
F3 Finds the next occurrence of the specified text.
CTRL+F3, CTRL+G Finds the next occurrence of the selected text.
SHIFT+F3 Finds the previous occurrence of the specified text.
CTRL+SHIFT+F3 Finds the previous occurrence of the selected text.
CTRL+DOWNARROW Scrolls window up without moving cursor.
CTRL+UPARROW Scrolls window down without moving cursor.
CTRL+LEFTARROW Moves the cursor one word to the left.
CTRL+RIGHTARROW Moves the cursor one word to the right.
F9 Inserts or removes a breakpoint.
CTRL+F9 Enables or disables a breakpoint.
CTRL+B Brings up Breakpoints dialog box.
ALT+F2 Adds/Removes Task List shortcut.
CTRL+U Makes the selection all lowercase.
CTRL+SHIFT+U Makes the selection all uppercase.
CTRL+BACKSPACE Deletes a word to the left.

Form Designer and Class Designer

Shortcut Action
CTRL+E Runs the form in the Form Designer.
CTRL+SHIFT+Click the control Drills down to a control in a container.
CTRL+Click the container Drills down through the container.

Help

Shortcut Action
F1 Displays Help Contents or context-sensitive Help on active items, for example, a highlighted keyword in the Command window or the current property in the Properties window.
SHIFT+F1 Enables user-prompted context-sensitive Help. The insertion pointer changes to a question mark so that you can click an item, for example, a menu command or toolbar, to display context-sensitive Help.
Shortcut Command
CTRL+A Select All on the Edit menu
CTRL+C Copy on the Edit menu
CTRL+D Do on the Program menu
CTRL+E Delete Item on the Menu menu
CTRL+E Do <program> on the Program menu

RunForm on the Form menu

CTRL+F Find on the Edit menu
CTRL+G Find Again on the Edit menu
CTRL+H Change Partitions on the Table menu
CTRL+I Insert Item on the Menu menu
CTRL+J Project Info on the Project menu
CTRL+L Replace on the Edit menu
CTRL+M Resume on the Program menu
CTRL+N New on the File menu
CTRL+O Open on the File menu
CTRL+P Print on the File menu
CTRL+Q Closes current text window and discards changes. See also CTRL+W.
Run Query on the Query menu
CTRL+R Redo on the Edit menu
CTRL+S Save on the File menu
CTRL+T Toggle Deletion Mark on the Table menu
CTRL+V Paste on the Edit menu
CTRL+W Closes current text window or dialog box and saves changes.
CTRL+X Cut on the Edit menu
CTRL+Y Append New Record on the Table menu
CTRL+Z Undo on the Edit menu
Shortcut Action
Z Zooms in and out of the page.
L Toggles between various zoom levels.
G Opens Goto page dialog box.
ESC Closes Print Preview window.
LEFTARROW Scrolls to the left of the page in the Print Preview window.
RIGHTARROW Scrolls to the right of the page in the Print Preview window.
UPARROW Scrolls towards the top of the page in the Print Preview window.
DOWNARROW Scrolls towards the bottom of the page in the Print Preview window.
PAGEDOWN Moves to the next page in the Print Preview window.
PAGEUP Moves to the previous page in the Print Preview window.
HOME Moves to the first page in the Print Preview window.
END Moves to the last page in the Print Preview window.

Properties Window

Shortcut Action
ALT+DOWN ARROW Expands the object list.
ALT+UP ARROW Closes the object list.
CTRL+PAGE DOWN or DOWN ARROW or RIGHT ARROW Moves to next object in the object list.
CTRL+PAGE UP or UP ARROW or LEFT ARROW Moves to previous object in object list.
CTRL+END Moves to last object in the object list.
CTRL+HOME Moves to first object in the object list.
TAB Moves to the next control in the Properties window.
SHIFT+TAB Moves to the previous control in the Properties window.
SHIFT+F10 Displays the appropriate shortcut menu.
CTRL+ALT+letter Selects the next property in the properties list that begins with the letter character. For example, pressing CTRL+ALT+B selects the next property that begins with B.

Report Designer

Shortcut Action
ALT+ENTER Opens the appropriate properties dialog box for a selected field.
CTRL+E Enters Edit mode for a Label control when it is selected in the Report designer.
ESC Exits Edit mode for a Label control and returns to Select mode.
TAB Enters Tab mode automatically and moves to the next object in the Report Designer.
SHIFT+TAB Moves to the previous object on the Report designer when in Tab mode.

Window Manipulation

Visual FoxPro preserves the order of windows and brings the newest window to the foreground instead of shifting the last window to the background when cycling through windows.

Shortcut Action
CTRL+F1 Cycles through windows.
CTRL+TAB Moves to the next window.
CTRL+SHIFT+TAB Moves to the previous window.
CTRL+F2 Displays Command window
CTRL+F4 Closes active window.
CTRL+F6 Moves to the next window.
CTRL+ALT+SHIFT Hides all child windows while the keys are pressed down. Hiding windows makes it easy to see output displayed in the main application window.
CTRL+F10 Toggles window size between maximum and restore.

See Also

Debugger Keyboard Shortcuts and Menus | Command Window | Class Browser Window