Skip to content

Commit 2fce485

Browse files
authored
Merge pull request #7011 from ghogen/azure-storage
Azure storage connected services article: update UI and project types supported
2 parents f62fec3 + d58e027 commit 2fce485

11 files changed

+64
-22
lines changed
Loading
Loading
Loading
Loading
Loading
Loading
Lines changed: 64 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,47 @@
11
---
22
title: Add Azure Storage by using Connected Services | Microsoft Docs
3-
description: Add Azure Storage to your app by using the Visual Studio Add Connected Services dialog box
3+
description: Add an Azure Storage service dependency to your app by using the Visual Studio Connected Services
44
author: ghogen
55
manager: jillfra
66
assetId: 521ec044-ad4b-4828-8864-01decde2e758
77
ms.custom: vs-azure
88
ms.workload: azure-vs
99
ms.topic: how-to
10-
ms.date: 03/26/2017
10+
ms.date: 08/13/2020
1111
ms.author: ghogen
1212
---
1313
# Adding Azure storage by using Visual Studio Connected Services
1414

15-
With Visual Studio, you can connect any of the following to Azure Storage by using the **Add Connected Services** dialog:
15+
With Visual Studio, you can connect any of the following to Azure Storage by using the **Connected Services** feature:
1616

17-
- C# cloud service
18-
- .NET backend mobile service
19-
- ASP.NET website or service
20-
- ASP.NET Core service
21-
- Azure WebJob service
17+
- .NET Framework console app
18+
- ASP.NET MVC (.NET Framework)
19+
- ASP.NET Core
20+
- .NET Core (including console app, WPF, Windows Forms, class Library)
21+
- .NET Core Worker Role
22+
- Azure Functions
23+
- Universal Windows Platform App
24+
- Xamarin
25+
- Cordova
2226

2327
The connected service functionality adds all the needed references and connection code to your project, and modifies your configuration files appropriately.
2428

25-
After completion, the **Add Connected Services** dialog automatically displays documentation detailing the steps required to start working with blob storage, queues, and tables.
26-
2729
> [!NOTE]
2830
> This topic applies to Visual Studio on Windows. For Visual Studio for Mac, see [Connected services in Visual Studio for Mac](/visualstudio/mac/connected-services).
31+
## Prerequisites
32+
33+
- Visual Studio with the Azure workload installed.
34+
- A project of one of the supported types
2935

30-
## Connect to Azure Storage using the Connected Services dialog
36+
## Connect to Azure Storage using Connected Services
3137

32-
1. Open your project in Visual Studio
38+
::: moniker range="vs-2017"
3339

34-
1. In **Solution Explorer**, right-click the **Connected Services** node, and, from the context menu, and select **Add Connected Service**.
40+
1. Open your project in Visual Studio.
3541

36-
![Add Azure connected service](./media/vs-azure-tools-connected-services-storage/IC796702.png)
42+
1. In **Solution Explorer**, right-click the **Connected Services** node, and, from the context menu, select **Add Connected Service**.
43+
44+
![Add Azure connected service](./media/vs-azure-tools-connected-services-storage/add-connected-service.png)
3745

3846
1. In the **Connected Services** page, select **Cloud Storage with Azure Storage**.
3947

@@ -56,19 +64,53 @@ After completion, the **Add Connected Services** dialog automatically displays d
5664
1. When the **Azure Storage** dialog is displayed, the new storage account appears in the list. Select the new storage account in the list, and select **Add**.
5765

5866
1. The storage connected service appears under the **Service References** node of your project.
67+
:::moniker-end
68+
69+
:::moniker range=">=vs-2019"
70+
71+
1. Open your project in Visual Studio.
72+
73+
1. In **Solution Explorer**, right-click the **Connected Services** node, and, from the context menu, select **Add Connected Service**.
74+
75+
![Add Azure connected service](./media/vs-azure-tools-connected-services-storage/vs-2019/add-connected-service.png)
76+
77+
1. In the **Connected Services** tab, select the + icon for **Service Dependencies**.
78+
79+
![Add Service Dependency](./media/vs-azure-tools-connected-services-storage/vs-2019/connected-services-tab.png)
80+
81+
1. In the **Add Dependency** page, select **Azure Storage**.
82+
83+
![Add Azure Storage](./media/vs-azure-tools-connected-services-storage/vs-2019/add-azure-storage.png)
84+
85+
1. In the **Azure Storage** dialog, select an existing storage account, and select **Add**.
86+
87+
If you need to create a storage account, go to the next step. Otherwise, skip to step 6.
88+
89+
![Add existing storage account to project](./media/vs-azure-tools-connected-services-storage/vs-2019/select-azure-storage-account.png)
90+
91+
1. To create a storage account:
92+
93+
1. Select **Create a New Storage Account** at the bottom of the dialog.
94+
95+
1. Fill out the **Create Storage Account** dialog, and select **Create**.
96+
97+
![New Azure storage account](./media/vs-azure-tools-connected-services-storage/vs-2019/create-storage-account.png)
98+
99+
1. When the **Azure Storage** dialog is displayed, the new storage account appears in the list. Select the new storage account in the list, and select **Add**.
59100

60-
## How your project is modified
101+
1. Enter a connection string name, and choose whether you want the connection string stored in a local secrets file, or in [Azure Key Vault](/azure/key-vault).
61102

62-
When you finish the dialog, Visual Studio adds references and modifies certain configuration files. The specific changes depend on the project type:
103+
![Specify connection string](./media/vs-azure-tools-connected-services-storage/vs-2019/connection-string.png)
63104

64-
- ASP.NET project - [What happened – ASP.NET Projects](/azure/visual-studio/vs-storage-aspnet-getting-started-blobs)
65-
- ASP.NET Core project - [What happened – ASP.NET 5 Projects](/azure/visual-studio/vs-storage-aspnet5-getting-started-blobs)
66-
- Cloud service project (web roles and worker roles) - [What happened – Cloud Service projects](/azure/visual-studio/vs-storage-cloud-services-getting-started-blobs)
67-
- WebJob project - [What happened - WebJob projects](/azure/visual-studio/vs-storage-webjobs-what-happened)
105+
1. The **Summary of changes** screen shows all the modifications that will be made to your project if you complete the process. If the changes look OK, choose **Finish**.
106+
107+
![Summary of changes](./media/vs-azure-tools-connected-services-storage/vs-2019/summary-of-changes.png)
108+
109+
1. The storage connected service appears under the **Service References** node of your project.
110+
:::moniker-end
68111

69112
## See also
70113

71-
- [MSDN Forum: Azure Storage](https://social.msdn.microsoft.com/forums/azure/home?forum=windowsazuredata)
72-
- [Microsoft Azure Storage Team Blog](https://blogs.msdn.microsoft.com/windowsazurestorage/)
114+
- [Azure Storage forum](https://social.msdn.microsoft.com/forums/azure/home?forum=windowsazuredata)
73115
- [Azure Storage documentation](/azure/storage/)
74116
- [Connected services (Visual Studio for Mac)](/visualstudio/mac/connected-services)

0 commit comments

Comments
 (0)