You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -80,7 +81,7 @@ You can use standard editing keys when you enter a command:
80
81
81
82
You can press the TAB key to automatically complete your text entry. In any of the debuggers, press the TAB key after you enter at least one character to automatically complete a command. Press the TAB key repeatedly to cycle through text completion options, and hold down the SHIFT key and press TAB to cycle backward. You can also use wildcard characters in the text and press TAB to expand to the full set of text completion options. For example, if you type **fo\*!ba** and then press TAB, the debugger expands to the set of all symbols that start with "ba", in all modules with module names that start with "fo". As another example, you can complete all extension commands that have "prcb" in them by typing **!\*prcb** and then pressing TAB.
82
83
83
-
When you use the TAB key to perform text completion, if your text fragment begins with a period (.), the text is matched to a dot command. If your text fragment begins with an exclamation point (!), the text is matched to an extension command. Otherwise, the text is matched with a symbol. When you usee the TAB key to enter symbols, pressing the TAB key completes code and type symbols and module names. If no module name is apparent, local symbols and module names are completed. If a module or module pattern is given, symbol completion completes code and type symbols from all matches.
84
+
When you use the TAB key to perform text completion, if your text fragment begins with a period (.), the text is matched to a dot command. If your text fragment begins with an exclamation point (!), the text is matched to an extension command. Otherwise, the text is matched with a symbol. When you use the TAB key to enter symbols, pressing the TAB key completes code and type symbols and module names. If no module name is apparent, local symbols and module names are completed. If a module or module pattern is given, symbol completion completes code and type symbols from all matches.
84
85
85
86
You can select and hold (or right-click) in the Debugger Command window to automatically paste the contents of the clipboard into the command that you are typing.
86
87
@@ -92,7 +93,7 @@ If the last command that you issued presents a long display and you want to cut
92
93
93
94
In kernel-mode debugging, you can cancel commands from the keyboard of the target computer by pressing [**CTRL+C**](../debugger/ctrl-c--break-.md).
94
95
95
-
You can use the [**.cls (Clear Screen)**](-cls--clear-screen-.md) command to clear all of the text from the [Debugger Command window](../debugger/debugger-command-window.md). This command clears the whole command history. In WinDbg, you can clear the command history by using the **Edit | Clear Command Output**command or by selecting **Clear command output** on the shortcut menu of the Debugger Command window.
96
+
You can use the [**.cls (Clear Screen)**](-cls--clear-screen-.md) command to clear all of the text from the [Debugger Command window](../debugger/debugger-command-window.md). This command clears the whole command history. In WinDbg, you can clear the command history by using **Clear History** on the **Command**ribbon tab, or by selecting **Clear command history** on the context menu (right-click) of the Command window.
96
97
97
98
### Expression Syntax
98
99
@@ -122,19 +123,23 @@ You can use the scrollbar to view your previous commands and their output.
122
123
123
124
When you are using CDB or KD, any keyboard entry automatically scrolls down the Debugger Command window back to the bottom.
124
125
125
-
In WinDbg, the display automatically scrolls down to the bottom whenever a command produces output or you press the ENTER key. If you want to disable this automatic scrolling, select the **Options** on the **View**menu and then clear the **Automatically scroll** check box.
126
+
In WinDbg, the display automatically scrolls down to the bottom whenever a command produces output or you press the ENTER key. If you want to disable this automatic scrolling, toggle off the **Auto Scroll**button on the **Command**ribbon tab, or right-click in the Command window and uncheck **Automatically scroll**.
126
127
127
128
### WinDbg Text Features
128
129
129
-
In WinDbg, you can use several additional features to change how text is displayed in the [Debugger Command window](../debugger/debugger-command-window.md). You can access some of these features in the WinDbg window, some in the shortcut menu in the Debugger Command window, and some by selecting the appropriate menu icon.
130
+
In WinDbg, you can use several additional features to change how text is displayed in the [Debugger Command window](../debugger/debugger-command-window.md). You can access some of these features from the **Command** ribbon tab and some from the context menu (right-click) in the Command window.
130
131
131
-
- The **Word wrap** command on the shortcut menu turns on and off the word wrap status. This command affects the whole window, not only commands that you use after this state is changed. Because many commands and extensions produce formatted displays, we typically do not recommend word wrap.
132
+
- The **Word wrap** command on the context menu turns on and off the word wrap status. This command affects the whole window, not only commands that you use after this state is changed. Because many commands and extensions produce formatted displays, we typically do not recommend word wrap.
132
133
133
-
- The **Edit | Add to Command Output** menu command adds a comment in the Debugger Command window. The **Add to command output** command on the shortcut menu has the same effect.
134
+
- The **Highlight Selection** button on the **Command** ribbon tab (or **Highlight selection** on the context menu) highlights or un-highlights the current text selection (Ctrl+Alt+H).
135
+
136
+
- The **Erase Selection** button on the **Command** ribbon tab (or **Erase selected text** on the context menu) erases the currently selected text from the command history.
137
+
138
+
- You can navigate between command sections using **Go to Previous** (Ctrl+[) and **Go to Next** (Ctrl+]) on the **Command** ribbon tab, or **Select previous command** and **Select next command** on the context menu.
134
139
135
140
- You can customize the colors that are used for the text and the background of the Debugger Command window. You can specify different colors for different kinds of text. For example, you can display the automatic register output in one color, error messages in another color, and **DbgPrint** messages in a third color.
136
141
137
-
- You can use all of the features common to WinDbg's debugging information windows, such as customizing the fonts and using special editing commands.
142
+
- You can use all of the features common to WinDbg's debugging information windows, such as customizing the fonts and using special editing commands.
Copy file name to clipboardExpand all lines: windows-driver-docs-pr/debuggercmds/windbg-command-line-preview.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,8 @@
2
2
title: 'WinDbg: Command-Line Startup Options'
3
3
description: "This section covers the command-line startup options for WinDbg."
4
4
keywords: ["Command line startup options", "WinDbg", "Menu", "Windows Debugging"]
5
-
ms.date: 09/11/2019
5
+
ms.date: 02/28/2026
6
+
ai-usage: ai-assisted
6
7
ms.topic: reference
7
8
---
8
9
@@ -29,6 +30,8 @@ The following tables summarize the available command-line options.
29
30
|`-c command`| Executes a command line after the debugger is attached. This command must be enclosed in quotation marks. Multiple commands can be separated with semicolons. |
30
31
|`-v`| Enables verbose output in the debugger. |
31
32
|`-T Title`| Sets the window title. |
33
+
|`-Q`| Disables automatic saving of settings. Settings changes are only persisted when you explicitly select **File** > **Save workspace** or **Save workspace as**. |
34
+
|`-WF SettingsFile`| Loads settings from the specified workspace file. |
32
35
|`-logo LogFile`| Log Open. Begins logging information to a log file. If the file exists, it will be overwritten. |
33
36
|`-loga LogFile`| Log Append. Begins logging information to a log file. If the file exists, it will be appended to. |
34
37
|`-e EventHandle`| Signals the event with the given handle after the next exception in a target. |
@@ -18,9 +19,9 @@ When you first open the **File** menu, you see **Start debugging** and your rece
18
19
19
20
#### Recent
20
21
21
-
The recent list contains a list of your recent workspaces and debugger connections. For more information on how to work with settingsand workspaces, see [WinDbg setup: Settingsand workspaces](windbg-setup-preview.md).
22
+
The recent list contains a list of your recent debug sessions and debugger connections. For more information on how to work with settings, workspaces, and debug sessions, see [WinDbg setup: Settings, workspaces, and saved debug sessions](windbg-setup-preview.md).
22
23
23
-
You can use the right-click menu to manage your workspaces, like pinning, renaming, and moving them. You can also edit them in Notepad.
24
+
You can use the right-click menu to manage your recent debug sessions, like pinning, renaming, and moving them. You can also edit them in Notepad.
24
25
25
26
:::image type="content" source="images/windbgx-workspace-right-click.png" alt-text="Right-click the menu for a workspace file with options to open, rename, edit in Notepad, pin, remove from lists, and clear unpinned targets.":::
26
27
@@ -29,18 +30,32 @@ You can use the right-click menu to manage your workspaces, like pinning, renami
29
30
Use the other tabs in the **Start debugging** section to start a new debugger session, like attaching or starting a process. For more information on starting a new session, see [WinDbg: Start a user-mode session](windbg-user-mode-preview.md)
30
31
and [WinDbg: Start a kernel mode session](windbg-kernel-mode-preview.md).
31
32
32
-
### Save workspace
33
+
### Save debug session
34
+
35
+
Use **Save debug session** to save the current target connection information to a file. Debug session files use the `.debugtarget` extension. This option is only available when a debug target is active.
36
+
37
+
The default location for debug session files is:
33
38
34
-
Use **Save workspace** to save the current workspace.
39
+
```console
40
+
C:\Users\*UserName*\AppData\Local\DBG\Targets
41
+
```
35
42
36
-
Session connection information is stored in workspace configuration files. Workspace files are stored with a .debugTarget file extension.
43
+
### Open workspace
37
44
38
-
The default location for workspace files is:
45
+
Use **Open workspace** to load settings from a previously saved workspace file. Workspace files use the `.xml` extension and are stored by default in:
39
46
40
47
```console
41
-
C:\Users\*UserName*\AppData\Local\DBG\targets
48
+
C:\Users\*UserName*\AppData\Local\DBG\Workspaces
42
49
```
43
50
51
+
### Save workspace
52
+
53
+
Use **Save workspace** to save the current settings to the active workspace file.
54
+
55
+
### Save workspace as
56
+
57
+
Use **Save workspace as** to save the current settings to a new workspace file.
58
+
44
59
### Open source file
45
60
46
61
Use **Open source file** to open a source file. Do this step when you want to work with other source files that didn't load because of code execution. For more information on working with source files, see [Source code debugging in WinDbg (Classic)](../debugger/source-window.md).
@@ -51,7 +66,7 @@ Use **Open script** to open an existing JavaScript or NatVis script. For more in
51
66
52
67
### Settings
53
68
54
-
Use **Settings** to set the source and symbol path and choose the light or dark theme for the debugger. For more information on settings, see [WinDbg setup: Settingsand workspaces](windbg-setup-preview.md).
69
+
Use **Settings** to set the source and symbol path and choose the theme for the debugger. The available themes are System (follows OS setting), Light, and Dark. For more information on settings, see [WinDbg setup: Settings, workspaces, and saved debug sessions](windbg-setup-preview.md).
# WinDbg: Notes, Command, Memory, and Source menus
10
11
11
-
This article describes how to work with the **Notes**, **Command**, **Memory**, and **Source** menus in WinDbg.
12
+
This article describes how to work with the **Notes**, **Command**, **Memory**, and **Source**ribbon tab menus in WinDbg. These ribbon tabs appear when the corresponding tool window is active.
12
13
13
14
## Notes
14
15
15
-
Use the **Notes**menu to:
16
+
Use the **Notes**ribbon tab to:
16
17
17
18
- Open a notes file.
18
19
- Save a notes file.
19
20
20
21
## Command
21
22
22
-
Use the **Command**menu to:
23
+
The **Command**ribbon tab appears when the Command window is active. It contains the following groups:
23
24
24
-
- Prefer Debugger Markup Language (DML).
25
-
- Highlight and clear highlighting for the current text selection (Ctrl+Alt+H).
26
-
- Clear the Command window text.
27
-
- Save window text to a .dml file.
25
+
### Preferences
26
+
27
+
-**Prefer DML** - Toggle whether commands in the engine provide plain text or Debugger Markup Language (DML) output, if available.
28
+
-**Auto Scroll** - Toggle whether the command window scroll position automatically synchronizes with the latest output.
29
+
30
+
### Selection
31
+
32
+
-**Highlight Selection** - Highlight or un-highlight the current text selection (Ctrl+Alt+H).
33
+
-**Erase Selection** - Erase the currently selected text from the command history.
34
+
-**Go to Previous** - Go to and select the previous command and its output (Ctrl+[).
35
+
-**Go to Next** - Go to and select the next command and its output (Ctrl+]).
36
+
37
+
### Actions
38
+
39
+
-**Clear History** - Erase all command window text.
40
+
-**Export History** - Write the command window text to a file.
41
+
42
+
### Command window context menu
43
+
44
+
You can also right-click in the Command window to access these options from a context menu:
0 commit comments