Skip to content

Commit a189cb0

Browse files
Merge pull request #11285 from MicrosoftDocs/main639101379343685075sync_temp
For protected branch, push strategy should use PR and merge to target branch method to work around git push error
2 parents c7c466d + 04ef21c commit a189cb0

9 files changed

Lines changed: 84 additions & 21 deletions

docs/designers/walkthrough-windows-forms-designer.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ author: ghogen
99
ms.author: ghogen
1010
manager: mijacobs
1111
ms.subservice: ui-designers
12+
ms.custom: awp-ai
1213
---
1314
# Tutorial: Get started with Windows Forms Designer
1415

@@ -344,3 +345,4 @@ This article has demonstrated how to construct the user interface for a simple c
344345
- [Windows Forms controls](/dotnet/framework/winforms/controls/)
345346
- [Accessibility for Windows Forms controls](/dotnet/framework/winforms/controls/providing-accessibility-information-for-controls-on-a-windows-form)
346347
- [Publish by using ClickOnce](../deployment/how-to-publish-a-clickonce-application-using-the-publish-wizard.md)
348+
- [Use .NET custom agents with GitHub Copilot](../ide/copilot-specialized-agents.md#net-development-agents)

docs/designers/windows-forms-designer-overview.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ author: ghogen
99
ms.author: ghogen
1010
manager: mijacobs
1111
ms.subservice: ui-designers
12+
ms.custom: awp-ai
1213
#customer intent: As a developer, I want to use Windows Forms Designer in Visual Studio, so I can arrange controls, set margins and padding, and adjust the layout, size, and display of forms.
1314
---
1415
# What is Windows Forms Designer?
@@ -39,8 +40,12 @@ When you work with Windows Forms Designer in Visual Studio, exercise caution in
3940

4041
- Resources in a _.resx_ file can be serialized by using the [BinaryFormatter](/dotnet/api/system.runtime.serialization.formatters.binary.binaryformatter) type. However, this type presents deserialization risks. The type is [insecure and not trustworthy](/dotnet/standard/serialization/binaryformatter-security-guide). Use Windows Forms Designer to work only with forms and controls that you trust.
4142

43+
> [!TIP]
44+
> Use the [WinForms Expert custom agent](../ide/copilot-specialized-agents.md#winforms-expert) with GitHub Copilot for AI-assisted guidance that protects your designer code, follows modern .NET patterns, and understands WinForms layout best practices.
45+
4246
## Related content
4347

4448
- [Windows Forms overview](/dotnet/framework/winforms/windows-forms-overview)
4549
- [Windows Forms controls](/dotnet/framework/winforms/controls/)
46-
- [User input in Windows Forms](/dotnet/framework/winforms/user-input-in-windows-forms)
50+
- [User input in Windows Forms](/dotnet/framework/winforms/user-input-in-windows-forms)
51+
- [Use built-in and custom agents with GitHub Copilot](../ide/copilot-specialized-agents.md)

docs/ide/ai-assisted-development-visual-studio.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,8 @@ GitHub Copilot and IntelliCode assist you in writing code faster and with greate
7777
:::image type="content" source="media/vs-2022/copilot-chat-visual-studio.gif" alt-text="Animated screenshot that shows the capabilities of the GitHub Copilot Chat extension." lightbox="media/vs-2022/copilot-chat-visual-studio.gif":::
7878

7979
Get started with [Copilot Chat in Visual Studio](visual-studio-github-copilot-chat.md#use-copilot-chat-in-visual-studio).
80+
81+
- **[Did You Mean search suggestions](visual-studio-search.md#did-you-mean-code-search-suggestions-preview)** uses Copilot to intelligently detect your intent when searching for files in All-In-One Search. If you mistype a query or can't remember an exact file name, Copilot suggests better matches based on what you might have meant. This feature helps you find files faster without having to correct typos or remember exact names.
8082

8183
### IntelliCode in Visual Studio
8284

docs/ide/copilot-edits.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,9 @@ ms.author: meghaanand
99
ms.manager: mijacobs
1010
ms.subservice: ai-tools
1111
ms.collection: ce-skilling-ai-copilot
12-
monikerRange: '>= vs-2022'
12+
monikerRange: 'vs-2022'
1313
ms.custom: awp-ai
14+
1415
---
1516
# What is GitHub Copilot Edits?
1617

@@ -84,7 +85,8 @@ Select **Accept all** to accept the proposed code changes across all files where
8485

8586
:::image type="content" source="media/vs-2022/copilot-edits/accept-all.gif" alt-text="Animated screenshot that shows accepting all edits on all files." lightbox="media/vs-2022/copilot-edits/accept-all.gif":::
8687

87-
### Revert edits
88+
89+
## Revert edits
8890

8991
#### Revert to the original state
9092

@@ -102,6 +104,7 @@ A popup dialog confirms the action before reverting file states.
102104

103105
:::image type="content" source="media/vs-2022/copilot-edits/reset-to-previous-iteration.png" alt-text="Screenshot that shows reverting a file to a previous iteration." lightbox="media/vs-2022/copilot-edits/reset-to-previous-iteration.png":::
104106

107+
105108
## Related content
106109

107110
- [GitHub Copilot agent mode](copilot-agent-mode.md)

docs/ide/copilot-specialized-agents.md

Lines changed: 46 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Use custom agents in GitHub Copilot
33
description: Learn about built-in agents for debugging, profiling, testing, and code modernization, and how to create custom agents for your team workflows.
4-
ms.date: 03/20/2026
4+
ms.date: 03/25/2026
55
ms.topic: how-to
66
author: mikejo5000
77
ms.author: mikejo
@@ -20,7 +20,7 @@ Visual Studio includes a set of curated built-in agents that integrate deeply wi
2020

2121
## Prerequisites
2222

23-
+ Visual Studio 2022 [version 17.14](/visualstudio/releases/2022/release-history) or later
23+
+ [Visual Studio 2026](/visualstudio/releases/2026/release-notes) or [Visual Studio 2022 version 17.14](/visualstudio/releases/2022/release-history) (with the latest servicing release recommended for the most up-to-date features)
2424
+ A [GitHub Copilot subscription](https://docs.github.com/en/copilot/about-github-copilot/what-is-github-copilot#getting-access-to-copilot)
2525

2626
## Access custom agents
@@ -52,14 +52,14 @@ You can access custom agents by using **@ syntax**: Type `@` followed by the age
5252

5353
## Built-in agents
5454

55-
Each built-in agent is designed around a specific developer workflow and integrates with Visual Studio's native tooling in ways that a generic assistant can't.
55+
Each built-in agent focuses on a specific developer workflow. These agents integrate with Visual Studio's native tooling in ways that a generic assistant can't.
5656

5757
:::moniker range="visualstudio"
5858
| Agent | Description |
5959
|-------|-------------|
6060
| **@debugger** | Goes beyond reading error messages. Uses your call stacks, variable state, and diagnostic tools to walk through error diagnosis systematically across your solution. |
6161
| **@profiler** | Connects to Visual Studio's profiling infrastructure to identify bottlenecks and suggest targeted optimizations grounded in your codebase, not generic advice. |
62-
| **@test** | Generates unit tests tuned to your project's framework and patterns, not boilerplate that your CI will reject. |
62+
| **@test** | Generates unit tests tuned to your project's framework and patterns, not boilerplate that your CI rejects. |
6363
| **@modernize** | (.NET and C++ only) Handles framework and dependency upgrades with awareness of your actual project graph. Flags breaking changes, generates migration code, and follows your existing patterns. |
6464
::: moniker-end
6565

@@ -115,11 +115,11 @@ For more comprehensive .NET testing support, see [GitHub Copilot testing for .NE
115115

116116
The @modernize agent helps with framework migrations and dependency upgrades for .NET and C++ projects.
117117

118-
For .NET modernization workflows, the agent can support a three-stage process:
118+
For .NET modernization workflows, the agent supports a three-stage process:
119119

120-
+ **Assessment**: Review package versions, target framework options, project inventory, and API compatibility risks.
121-
+ **Plan**: Generate a migration plan that aligns with the current assessment and update priorities.
122-
+ **Task execution**: Work through modernization tasks with a dynamic task file you can edit as the work progresses.
120+
+ **Assessment**: Reviews package versions, target framework options, project inventory, and API compatibility risks.
121+
+ **Plan**: Generates a migration plan that aligns with the current assessment and update priorities.
122+
+ **Task execution**: Works through modernization tasks with a dynamic task file you can edit as the work progresses.
123123

124124
**Example prompts**:
125125

@@ -137,13 +137,13 @@ For end-to-end guidance on GitHub Copilot app modernization for .NET, see [GitHu
137137
> [!NOTE]
138138
> Custom agents require Visual Studio 2026 version 18.4 or later.
139139
140-
The built-in agents cover common workflows, but your team knows your workflow best. Custom agents let you build your own using the same foundation: workspace awareness, code understanding, your preferred AI model, and your own tools.
140+
The built-in agents cover common workflows, but your team knows your workflow best. Custom agents let you build your own agents by using the same foundation: workspace awareness, code understanding, your preferred AI model, and your own tools.
141141

142142
Custom agents become especially powerful when combined with [MCP (Model Context Protocol)](mcp-servers.md). You can connect agents to external knowledge sources like internal documentation, design systems, APIs, and databases, so the agent isn't limited to what's in your repository.
143143

144144
### Create a custom agent
145145

146-
Custom agents are defined as `.agent.md` files in your repository's `.github/agents/` folder:
146+
Define custom agents as `.agent.md` files in your repository's `.github/agents/` folder:
147147

148148
```text
149149
your-repo/
@@ -185,10 +185,10 @@ Flag violations clearly and suggest fixes inline.
185185

186186
| Property | Required | Description |
187187
|----------|----------|-------------|
188-
| `name` | No | Display name for the agent in the agent picker. If not specified, the agent name is derived from the filename (for example, `code-reviewer.agent.md` becomes `code-reviewer`). |
188+
| `name` | No | Display name for the agent in the agent picker. If you don't specify this property, the agent name comes from the filename (for example, `code-reviewer.agent.md` becomes `code-reviewer`). |
189189
| `description` | Yes | Brief description shown when hovering over the agent |
190-
| `model` | No | AI model to use. If not specified, uses the model selected in the model picker. |
191-
| `tools` | No | Array of tool names the agent can use. If not specified, all available tools are enabled. |
190+
| `model` | No | AI model to use. If you don't specify this property, the model selected in the model picker is used. |
191+
| `tools` | No | Array of tool names the agent can use. If you don't specify this property, all available tools are enabled. |
192192

193193
### Specify tools
194194

@@ -199,14 +199,14 @@ Tools extend what your custom agent can do. You can specify which tools the agen
199199
200200
### Connect to external sources with MCP
201201

202-
With [MCP servers](mcp-servers.md), your custom agents can access external knowledge sources:
202+
By using [MCP servers](mcp-servers.md), your custom agents can access external knowledge sources such as:
203203

204204
+ Internal documentation and wikis
205205
+ Design systems and component libraries
206206
+ APIs and databases
207207
+ Style guides and ADR repositories
208208

209-
For example, a code review agent can check PRs against your actual conventions by connecting to your style guide via MCP.
209+
For example, a code review agent can check PRs against your actual conventions by connecting to your style guide through MCP.
210210

211211
### Example custom agents
212212

@@ -292,9 +292,39 @@ Always check existing code conventions before making changes.
292292
> [!TIP]
293293
> Select the **Tools** icon in the Copilot Chat window to see all available tool names in your version of Visual Studio.
294294
295+
### .NET development agents
296+
297+
The .NET team maintains curated custom agents for C# and Windows Forms development in the [awesome-copilot](https://github.com/github/awesome-copilot) repository. To get started:
298+
299+
1. Download [CSharpExpert.agent.md](https://github.com/github/awesome-copilot/blob/main/agents/CSharpExpert.agent.md) and [WinFormsExpert.agent.md](https://github.com/github/awesome-copilot/blob/main/agents/WinFormsExpert.agent.md).
300+
1. Add the files to your repository's `.github/agents/` folder.
301+
1. Open Copilot Chat in agent mode and select the agent from the agent picker.
302+
303+
> [!TIP]
304+
> Select **Tools** > **Options** > **GitHub** > **Copilot**, and then enable **Enable project specific .NET instructions such as Windows Forms development when applicable** to automatically add the appropriate custom agent for your code base.
305+
306+
#### C# Expert
307+
308+
The C# Expert agent applies modern C# conventions to Copilot's code generation:
309+
310+
+ **Syntax and performance**: Follows current best practices while matching your repository's existing conventions.
311+
+ **Minimal changes**: Generates only the code needed, using async/await with proper cancellation and exception handling. Avoids unused interfaces, methods, or parameters.
312+
+ **Testing**: Supports behavior-driven unit testing, integration testing, and TDD workflows.
313+
314+
#### WinForms Expert
315+
316+
The WinForms Expert agent targets Windows Forms development on .NET 8 through .NET 10:
317+
318+
+ **Designer code protection**: Prevents `.Designer.cs` corruption so the [Windows Forms Designer](../designers/windows-forms-designer-overview.md) keeps working after Copilot edits.
319+
+ **UI design patterns**: MVVM and MVP patterns, including Community Toolkit data binding.
320+
+ **Modern .NET**: Correct `InvokeAsync` overloads, dark mode, high-DPI awareness, and nullable reference types.
321+
+ **Layout**: `TableLayoutPanel` and `FlowLayoutPanel` for responsive, DPI-aware layouts.
322+
+ **CodeDOM serialization**: `[DefaultValue]` attributes and `ShouldSerialize*()` methods for proper designer property handling.
323+
+ **Exception handling**: Async event handler patterns and application-level exception handling.
324+
295325
### Community configurations
296326

297-
The [awesome-copilot repository](https://github.com/github/awesome-copilot) has community-contributed agent configurations you can use as starting points. When using configurations from this repository, verify tool names work in Visual Studio before deploying to your team.
327+
The [awesome-copilot repository](https://github.com/github/awesome-copilot) has community-contributed agent configurations you can use as starting points. When you use configurations from this repository, verify tool names work in Visual Studio before deploying to your team.
298328

299329
### Limitations and notes
300330

28.9 KB
Loading
154 KB
Loading
142 KB
Loading

docs/ide/visual-studio-search.md

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ helpviewer_keywords:
1212
- windows [Visual Studio], navigating
1313
- Window.QuickLaunch
1414
- IDE navigator
15-
monikerRange: ">=vs-2022"
1615
author: ghogen
1716
ms.author: ghogen
1817
manager: mijacobs
1918
ms.subservice: general-ide
19+
ms.custom: awp-ai
2020
---
2121
# Use Visual Studio search
2222

@@ -40,7 +40,28 @@ For example, suppose you searched for "prettify file" in Feature Search. That do
4040

4141
:::image type="content" source="./media/vs-2022/feature-search-ask-copilot-prettify.png" lightbox="./media/vs-2022/feature-search-ask-copilot-prettify.png" alt-text="Screenshot showing the Ask Copilot button in All-In-One Search.":::
4242

43-
In Code Search, if you mistype a search query, Visual Studio can often detect this and suggest a possible correction. If a variation of the text you entered returns much better results, you'll see a message ("Did you mean ... ?") that suggests the alternate query. Just click on this message to accept the suggested query and refresh the results.
43+
### Did You Mean code search suggestions (preview)
44+
45+
Ever forget the name of a file while coding? The **Did You Mean** feature in Visual Studio, powered by Copilot, helps you find files even when you can't remember their exact names. When you search using All-In-One Search and Copilot detects a better match than the top result—perhaps because of a typo or a fuzzy memory—it suggests what you might have meant.
46+
47+
:::image type="content" source="./media/visualstudio/did-you-mean.png" alt-text="Screenshot of the Did You Mean suggestion.":::
48+
49+
When you type a search term, Copilot analyzes your input and suggests a more relevant term if it finds one that more closely matches your intent. This feature helps whether the search results are empty or when the top result isn't what you intended. Select the suggestion to accept it and refresh the results.
50+
51+
:::image type="content" source="./media/visualstudio/did-you-mean-empty.png" alt-text="Screenshot of the Did You Mean suggestion appearing when search results are empty.":::
52+
53+
:::image type="content" source="./media/visualstudio/did-you-mean-non-empty.png" alt-text="Screenshot of the Did You Mean feature showing an alternative suggestion when the top result doesn't match your intent.":::
54+
55+
**Did You Mean** speeds up your search experience by reducing the time spent correcting typos or trying to remember the correct name—making your search experience easier and more intuitive.
56+
57+
#### Enable or disable Did You Mean
58+
59+
To control this feature:
60+
61+
1. In Visual Studio, go to **Tools** > **Options** > **GitHub** > **Copilot** > **Search**.
62+
1. Select or clear **Enable 'Did You Mean' Code Search Support in All-In-One Search (preview)**.
63+
64+
### Recently navigated files
4465

4566
When you open Code Search without a query, you'll see a list of your recently navigated files. These include the files you opened through Code Search, but also any other files you opened in the solution. This makes it easy to jump back to a file you were recently working on without having to remember or type the file name.
4667

0 commit comments

Comments
 (0)