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
Copy file name to clipboardExpand all lines: docs/ide/quick-actions.md
+17-12Lines changed: 17 additions & 12 deletions
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
2
title: Quick Actions, light bulbs, and screwdrivers
3
3
description: Use a single Quick Action in Visual Studio to refactor, generate, or modify your C#, C++, or Visual Basic code files to apply updates and fixes or generate code.
4
-
ms.date: 08/14/2024
4
+
ms.date: 11/01/2024
5
5
ms.topic: concept-article
6
6
author: Mikejo5000
7
7
ms.author: mikejo
@@ -37,6 +37,22 @@ Visual Studio uses several icons to indicate when Quick Actions are available. T
37
37
38
38
For any language, third parties can provide custom diagnostics and suggestions, such as part of an SDK. Visual Studio shows light bulbs based on those rules.
39
39
40
+
## Find available actions
41
+
42
+
You can check your code for available Quick Actions in Visual Studio by scanning for the light bulb , screwdriver , and error light bulb :
43
+
44
+
- Move your mouse over your code and notice any Quick Action icons:
45
+
46
+
:::image type="content" source="../ide/media/vs2022-lightbulb-hover.png" border="false" alt-text="Screenshot that shows the basic Quick Action recommendation and light bulb icon in Visual Studio.":::
47
+
48
+
- Move the insertion cursor (|) into a line of code, and check for Quick Action icons in the left margin of the code editor.
49
+
50
+
You can also manually check for any available Quick Actions:
51
+
52
+
- Right-click a line of code and choose **Quick Actions and Refactorings** for a list of available Quick Actions and refactoring options.
53
+
54
+
- Select Ctrl + period (.) anywhere on a line.
55
+
40
56
## Apply recommendations to improve code
41
57
42
58
When Quick Actions are available, you can select the light bulb  or screwdriver  icon next to the applicable code.
@@ -60,17 +76,6 @@ If there's an error in your code, and Visual Studio has a recommended fix, you s
60
76
> [!TIP]
61
77
> You can turn off some of the code fix Quick Actions. For more informatio, see [Disable source code analysis for .NET](../code-quality/disable-code-analysis.md).
62
78
63
-
## Find available actions
64
-
65
-
You can check your code for available Quick Actions in Visual Studio by scanning for the light bulb , screwdriver , and error light bulb :
66
-
67
-
- Move your mouse over your code and notice any Quick Action icons:
68
-
69
-
:::image type="content" source="../ide/media/vs2022-lightbulb-hover.png" border="false" alt-text="Screenshot that shows the basic Quick Action recommendation and light bulb icon in Visual Studio.":::
70
-
71
-
- Move the insertion cursor (|) into a line of code, and check for Quick Action icons in the left margin of the code editor.
72
-
73
-
- Select Ctrl + period (.) anywhere on a line for a list of available Quick Actions and refactoring options.
0 commit comments