Skip to content

Commit a04675a

Browse files
Merge pull request #8574 from MicrosoftDocs/main
Auto Publish – main to live - 2025-11-14 22:00 UTC
2 parents d752406 + f6c1778 commit a04675a

File tree

6 files changed

+155
-114
lines changed

6 files changed

+155
-114
lines changed

docs/boards/queries/import-work-items-from-csv.md

Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ms.author: chcomley
99
author: chcomley
1010
ms.topic: how-to
1111
monikerRange: "<=azure-devops"
12-
ms.date: 11/26/2024
12+
ms.date: 11/14/2025
1313
#customer intent: As a team member, I want to import and export work items in CSV format to create or update them in bulk by using Excel.
1414
---
1515

@@ -43,15 +43,29 @@ To import work items in bulk, your CSV file must include the **Work Item Type**
4343
- Verify that all fields in the CSV file match the fields for the work item types in the target project.
4444
- **Handle invalid values:** If the imported CSV file contains work items with invalid values, you must edit and correct these work items after import before they can be saved.
4545

46+
> [!TIP]
47+
> Work item fields vary between different process templates (Agile, Scrum, CMMI) and Azure DevOps versions. Before importing, verify the available fields for your work item types by:
48+
> 1. Creating a sample work item of the desired type in your project
49+
> 2. Viewing the available fields in the work item form
50+
> 3. Or exporting existing work items to see the current field structure
51+
>
52+
> Field names and availability might differ from the examples shown in this article based on your process template and Azure DevOps version.
53+
4654
Do the following steps to import new work items.
4755

4856
> [!NOTE]
4957
> You can import up to 1,000 work items at a time. If you have more than 1,000 work items to import, break them into multiple files and import them separately.
5058
5159
1. Create a local *import.csv* file and open it in Visual Studio Code or Excel.
52-
2. The file must contain the **Work Item Type** and the **Title** fields. You can include other fields as needed. For a list of default fields, see [Work item field index](../work-items/guidance/work-item-field.md).
60+
2. The file must contain the **Work Item Type** and the **Title** fields. You can include other fields as needed.
61+
62+
> [!TIP]
63+
> To determine the correct field names for your Azure DevOps instance:
64+
> - Export a few existing work items from your project to view the exact field names
65+
> - Create a new work item and review the available fields
66+
> - Check the [Work item field index](../work-items/guidance/work-item-field.md) for standard field references
5367
54-
The following example includes the **Priority** field.
68+
The following example includes the **Priority** field. Your available fields might differ based on your process template:
5569

5670
```csv
5771
Work Item Type,Title,Priority
@@ -85,6 +99,13 @@ Do the following steps to import new work items.
8599

86100
### Tips
87101

102+
- **Field compatibility:** Different Azure DevOps versions and process templates (Agile, Scrum, CMMI, or custom) have different available fields. Always verify field names by exporting existing work items from your project before importing new ones.
103+
- **Process template differences:**
104+
- **Agile process**: Uses User Story, Task, Bug, Epic, Feature, Test Case
105+
- **Scrum process**: Uses Product Backlog Item, Task, Bug, Epic, Feature, Test Case
106+
- **CMMI process**: Uses Requirement, Task, Bug, Epic, Feature, Test Case
107+
- Your field names and available options might vary based on which process your project uses.
108+
88109
- **Parent-child links:** You can add parent-child links between work items you import by indenting the title columns, as shown in [Can I import a CSV file that have parent-child links?](#tree-items). However, you can't specify any other link types when you import or update work items.
89110
- **Default State field:** When you import new work items, the **State** field is set to *New* by default. You can't specify a different state during the import process. If you need to change the state of imported work items, use the following workaround:
90111

@@ -120,7 +141,7 @@ Do the following steps to import new work items.
120141
1. Make the edits to your work items. Your CSV file must contain the **ID**, **Work Item Type**, and **Title** fields. Any other fields you want to include are optional.
121142

122143
> [!NOTE]
123-
> When you import identity fields, enter the name and email in the following format `"Display Name <email>"`. For example, to assign work to Jamal Hartnett, specify `"Jamal Hartnett <[email protected]>"`. If you specify a value that isn't recognized as a valid user to the system, you may encounter problems with the import.
144+
> When you import identity fields, enter the name and email in the following format `"Display Name <email>"`. For example, to assign work to Jamal Hartnett, specify `"Jamal Hartnett <[email protected]>"`. If you specify a value that isn't recognized as a valid user to the system, you might encounter problems with the import.
124145
125146
In the following example, we change values on existing working items.
126147

docs/extend/develop/using-host-dialog.md

Lines changed: 60 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ai-usage: ai-assisted
88
monikerRange: '<= azure-devops'
99
ms.author: chcomley
1010
author: chcomley
11-
ms.date: 07/02/2025
11+
ms.date: 11/14/2025
1212
# customer-intent: As an Azure DevOps extension developer, I want to create modal dialogs that block user interaction with the entire page so I can collect user input, display forms, and provide focused user experiences in my extensions.
1313
---
1414

@@ -29,8 +29,6 @@ Use modal dialogs in your extensions to:
2929
3030
## Prerequisites
3131

32-
Before you can create modal dialogs in your Azure DevOps extension, ensure you have the following:
33-
3432
| Category | Requirement | Details |
3533
|----------|-------------|---------|
3634
| **Extension setup** | Working extension project | A valid `vss-extension.json` manifest file |
@@ -42,7 +40,7 @@ Before you can create modal dialogs in your Azure DevOps extension, ensure you h
4240
| **Required packages** | Extension SDK | Install: `npm install azure-devops-extension-sdk` |
4341
| | Extension API | Install: `npm install azure-devops-extension-api` |
4442
| **Extension permissions** | Manifest scopes | Include appropriate scopes in `vss-extension.json`, for example: `"vso.work"`, `"vso.project"` |
45-
| **SDK imports** | Required modules | Import SDK and services: `import * as SDK from "azure-devops-extension-sdk"` and `import { CommonServiceIds, IHostDialogService } from "azure-devops-extension-api"` |
43+
| **SDK imports** | Required modules | Import SDK and services: `import * as SDK from "azure-devops-extension-sdk"` |
4644

4745
## Dialog contents
4846

@@ -140,78 +138,76 @@ The `uri` property references a page that is rendered within the content area of
140138

141139
## Show the dialog
142140

143-
To show the dialog (for example, when a user selects an action on a toolbar or menu), call the `openDialog` function on an instance of the HostDialogService, passing the fully qualified identifier of the dialog content, for example `my-publisher.my-extension.registration-form` and any dialog options:
141+
To show the dialog (for example, when a user selects an action on a toolbar or menu), call the `openDialog` function on an instance of the HostDialogService:
144142

145143
```javascript
146-
import * as SDK from "azure-devops-extension-sdk";
147-
148-
SDK.getService<IHostDialogService>(CommonServiceIds.HostDialogService).then((dialogService) => {
149-
const extensionCtx = SDK.getExtensionContext();
150-
// Build absolute contribution ID for dialogContent
151-
const contributionId = `${extensionCtx.publisherId}.${extensionCtx.extensionId}.registration-form`;
152-
153-
// Show dialog
154-
const dialogOptions = {
155-
title: "My Dialog",
156-
width: 800,
157-
height: 600
158-
};
159-
160-
dialogService.openDialog(contributionId, dialogOptions);
161-
});
144+
import * as SDK from "azure-devops-extension-sdk";
145+
146+
SDK.getService(SDK.CommonServiceIds.HostDialogService).then((dialogService) => {
147+
const extensionCtx = SDK.getExtensionContext();
148+
// Build absolute contribution ID for dialogContent
149+
const contributionId = `${extensionCtx.publisherId}.${extensionCtx.extensionId}.registration-form`;
150+
151+
// Show dialog
152+
const dialogOptions = {
153+
title: "My Dialog",
154+
width: 800,
155+
height: 600
156+
};
157+
158+
dialogService.openDialog(contributionId, dialogOptions);
159+
});
162160
```
163161

164162
## Advanced dialog features
165163

166-
A function can be called when the OK button is selected. This function is specified by `getDialogResult` in the options you provide when showing the dialog.
164+
A function can be called when the OK button is selected. You specify this function by setting `getDialogResult` in the options you provide when showing the dialog.
167165

168166
If a call to `getDialogResult` returns a non-null value, this value is then passed to the function specified by `okCallback` (also in the options) and the dialog is closed.
169167

170168
In this example, the `attachFormChanged` callback gets called when inputs on the form change. Based on whether the form is valid or not, the OK button is enabled or disabled.
171169

172170
```javascript
173-
import * as SDK from "azure-devops-extension-sdk";
174-
import { CommonServiceIds, IHostDialogService } from "azure-devops-extension-api";
175-
176-
SDK.getService<IHostDialogService>(CommonServiceIds.HostDialogService).then((dialogService) => {
177-
let registrationForm: any;
178-
const extensionCtx = SDK.getExtensionContext();
179-
const contributionId = `${extensionCtx.publisherId}.${extensionCtx.extensionId}.registration-form`;
180-
181-
const dialogOptions = {
182-
title: "Registration Form",
183-
width: 800,
184-
height: 600,
185-
getDialogResult: () => {
186-
// Get the result from registrationForm object
187-
return registrationForm ? registrationForm.getFormData() : null;
188-
},
189-
okCallback: (result: any) => {
190-
// Log the result to the console
191-
console.log(JSON.stringify(result));
192-
}
193-
};
194-
195-
dialogService.openDialog(contributionId, dialogOptions).then((dialog) => {
196-
// Get registrationForm instance which is registered in registrationFormContent.html
197-
dialog.getContributionInstance("registration-form").then((registrationFormInstance) => {
171+
import * as SDK from "azure-devops-extension-sdk";
172+
173+
SDK.getService(SDK.CommonServiceIds.HostDialogService).then((dialogService) => {
174+
let registrationForm;
175+
const extensionCtx = SDK.getExtensionContext();
176+
const contributionId = `${extensionCtx.publisherId}.${extensionCtx.extensionId}.registration-form`;
177+
178+
const dialogOptions = {
179+
title: "Registration Form",
180+
width: 800,
181+
height: 600,
182+
getDialogResult: () => {
183+
// Get the result from registrationForm object
184+
return registrationForm ? registrationForm.getFormData() : null;
185+
},
186+
okCallback: (result) => {
187+
// Log the result to the console
188+
console.log(JSON.stringify(result));
189+
}
190+
};
191+
192+
dialogService.openDialog(contributionId, dialogOptions).then((dialog) => {
193+
// Get registrationForm instance which is registered in registrationFormContent.html
194+
dialog.getContributionInstance("registration-form").then((registrationFormInstance) => {
195+
196+
// Keep a reference of registration form instance (to be used previously in dialog options)
197+
registrationForm = registrationFormInstance;
198198

199-
// Keep a reference of registration form instance (to be used previously in dialog options)
200-
registrationForm = registrationFormInstance;
201-
202-
// Subscribe to form input changes and update the Ok enabled state
203-
registrationForm.attachFormChanged((isValid: boolean) => {
204-
dialog.updateOkButton(isValid);
205-
});
206-
207-
// Set the initial ok enabled state
208-
registrationForm.isFormValid().then((isValid: boolean) => {
209-
dialog.updateOkButton(isValid);
210-
});
211-
});
212-
});
199+
// Subscribe to form input changes and update the Ok enabled state
200+
registrationForm.attachFormChanged((isValid) => {
201+
dialog.updateOkButton(isValid);
202+
});
203+
204+
// Set the initial ok enabled state
205+
registrationForm.isFormValid().then((isValid) => {
206+
dialog.updateOkButton(isValid);
207+
});
208+
});
213209
});
214-
210+
});
215211
```
216212

217213
## Control the OK button
@@ -227,7 +223,7 @@ Initially, the OK button is disabled. However, you can enable/disable this butto
227223

228224
## Pass values to the dialog
229225

230-
It's possible to pass initial values to dialog content when it is opened in the host dialog.
226+
It's possible to pass initial values to dialog content when you open it in the host dialog.
231227

232228
```json
233229
{
@@ -241,7 +237,7 @@ It's possible to pass initial values to dialog content when it is opened in the
241237
}
242238
```
243239

244-
When the dialog is opened, following options need to be specified to pass `myId`:
240+
When the dialog opens, the following options must be specified to pass `myId`:
245241

246242
```javascript
247243
const dialogOptions = {

0 commit comments

Comments
 (0)