Visual Studio
01 / 04

Navigation & Shortcuts

Visual Studio Navigation & Shortcuts

Visual Studio (the full Microsoft IDE — not VS Code) has hundreds of keyboard shortcuts. Mastering the navigation shortcuts eliminates mouse dependency and dramatically speeds up code exploration across large .NET solutions.

Essential Navigation Shortcuts

# Go To / Search
Ctrl+,          # Go To All — search types, files, members, symbols (replaces Ctrl+T in older VS)
Ctrl+T          # Go To All (alternate binding — same as Ctrl+,)
Ctrl+Shift+T    # Go To Recent Files — jump to recently opened files
Ctrl+G          # Go To Line number
Ctrl+;          # Search Solution Explorer from keyboard

# Find References / Navigation
F12             # Go To Definition — jump to where symbol is defined
Ctrl+F12        # Go To Implementation — jump to implementation (skips interface)
Shift+F12       # Find All References — all usages of symbol in solution
Alt+F12         # Peek Definition — inline definition view (no new tab)
Ctrl+- (minus)  # Navigate Backward — go back in navigation history
Ctrl+Shift+-    # Navigate Forward
Ctrl+Alt+B      # Go To Base — navigate up the inheritance chain

# Code search
Ctrl+F          # Find in current file
Ctrl+H          # Find and Replace in current file
Ctrl+Shift+F    # Find in Files (entire solution)
Ctrl+Shift+H    # Replace in Files (entire solution)

# Solution Explorer
Ctrl+Alt+L      # Show/focus Solution Explorer
Alt+F7          # Show Properties window
Ctrl+[, S       # Sync Solution Explorer to current document (track active item)
                # Enable via: Tools → Options → Projects and Solutions → Track Active Item

# Window management
Ctrl+F4         # Close current document
Ctrl+Tab        # Navigate open document tabs (IDE Navigator popup)
Ctrl+W          # Close current tab (custom binding you may need to add)
Shift+Esc       # Close tool window / return focus to editor

Code Editing & IntelliSense

# IntelliSense & Completion
Ctrl+Space      # Trigger IntelliSense completion
Ctrl+Shift+Space # Show parameter info (method signature)
Ctrl+.          # Quick Actions / Light Bulb — fixes, refactors, generate code
Alt+Enter       # ReSharper equivalent to Ctrl+. (if ReSharper installed)

# Code editing
Ctrl+K, Ctrl+C  # Comment selected lines (// or /* */)
Ctrl+K, Ctrl+U  # Uncomment selected lines
Ctrl+K, Ctrl+D  # Format entire document (auto-indent)
Ctrl+K, Ctrl+F  # Format selected code only
Ctrl+K, Ctrl+E  # Error List — show all errors/warnings
Tab             # Indent selected block
Shift+Tab       # Unindent selected block
Ctrl+D          # Duplicate current line (may need to add via Tools → Options → Keyboard)
Ctrl+L          # Delete current line
Ctrl+Shift+L    # Delete current line (alternate)
Ctrl+X          # Cut current line (nothing selected — cuts whole line)

# Bookmarks
Ctrl+K, Ctrl+K  # Toggle bookmark on current line
Ctrl+K, Ctrl+N  # Next bookmark
Ctrl+K, Ctrl+P  # Previous bookmark
Ctrl+K, Ctrl+L  # Clear all bookmarks
Ctrl+K, Ctrl+W  # Bookmark Window — view all bookmarks

# Code folding
Ctrl+M, Ctrl+O  # Collapse all code (outline)
Ctrl+M, Ctrl+L  # Expand all code
Ctrl+M, Ctrl+M  # Toggle collapse/expand current block

CodeLens & Go To All

CodeLens displays inline metadata above methods and types — reference counts, test status, Git history, and work item links. Go To All (Ctrl+,) is the single most powerful navigation tool in Visual Studio.

# CodeLens — enable/disable: Tools → Options → Text Editor → All Languages → CodeLens
# Shows above each method/class:
# - "X references"           → click to see all callers
# - "0/1 test passing"       → click to run the test
# - "N authors"              → click to see Git blame / history
# - "N work items"           → Azure DevOps linked items

# CodeLens keyboard shortcut
Alt+` (backtick)  # Focus CodeLens indicators for current method
Escape            # Dismiss CodeLens popup

# Go To All — Ctrl+, — filtered search prefixes:
# (no prefix)  → search everything (types, members, files, symbols)
# f <name>     → files only (e.g. "f HomeController")
# t <name>     → types only (e.g. "t IUserService")
# m <name>     → members only (e.g. "m ProcessPayment")
# #<name>      → Git history / symbol (same as t)
# :<line>      → go to line in current file (e.g. ":250")

# Solution Explorer search
# Click the search box in Solution Explorer (or Ctrl+;)
# Type to filter files/projects by name
# Supports wildcards: *.cs, *Controller*

# Task List (TODO/HACK/FIXME tracking)
# View → Task List
# VS scans comments for: TODO, HACK, UNDONE (configurable)
# Add custom tokens: Tools → Options → Environment → Task List

Keep your own version of these notes — editable, searchable, and organised by your stack.

Start free