如何在 Visual Studio 中打开现有的 azure 功能?

2

本文介绍了如何在 Visual Studio 中打开现有的 azure 功能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

问题描述

我是 Azure 的新手,我使用门户编写了一个 Azure 函数.现在我想继续使用 Visual Studio 2017 进行处理.不过,我似乎找不到在 Visual Studio 中打开/编辑这个现有函数的方法.

I'm pretty new to Azure and using the portal, wrote an Azure Function. Now I would like to continue working on it using Visual Studio 2017. I can't seem to find a way to open/edit this existing function in Visual Studio though.

我确信我可以在 VS 中创建一个新的 Azure 函数、复制代码、设置/连接到存储等,并部署一个新实例并删除当前实例,但我想避免这种情况.

I'm sure I could create a new Azure Function in VS, copy code over, setup/connect to storage, etc. and deploy a new instance and delete the current instance, but would like to avoid that.

理想情况下,希望在 VS 中有某种打开/连接到 Azure 帐户,或者可能是门户中的在 VS 中编辑"按钮等.

Ideally, was hoping there was some kind of open/connect to Azure account in VS, or maybe an "edit in VS" button in the portal, etc.

TIA!

推荐答案

好吧,尽可能接近的是转到门户,您的 Function App,然后单击 Download app content按钮并询问 Visual Studio 解决方案:

Well, as close as you can get to that is to go to the portal, your Function App, then click Download app content button and ask for Visual Studio solution:

这将为您提供一个包含函数的 zip 文件,包括 csproj 文件.

This will give you a zip file with Functions, including csproj file.

问题是门户函数是 C# 脚本(csx 文件),Visual Studio 不能很好地使用它们.当您在 Visual Studio 2017 中创建新的函数应用程序时,它将生成一个 预编译 函数项目 - 一个带有 cs 文件的普通类库.

The problem is that portal functions are C# scripts (csx files), and Visual Studio isn't great to work with them. When you create a new Function App in Visual Studio 2017, it will make a precompiled function project - a normal class library with cs files.

不幸的是,没有自动方法将脚本函数转换为预编译函数.

Unfortunately, there is no automated way to convert script functions to precompiled ones.

这篇关于如何在 Visual Studio 中打开现有的 azure 功能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

The End

相关推荐

C# 中的多播委托奇怪行为?
Multicast delegate weird behavior in C#?(C# 中的多播委托奇怪行为?)...
2023-11-11 C#/.NET开发问题
6

参数计数与调用不匹配?
Parameter count mismatch with Invoke?(参数计数与调用不匹配?)...
2023-11-11 C#/.NET开发问题
26

如何将代表存储在列表中
How to store delegates in a List(如何将代表存储在列表中)...
2023-11-11 C#/.NET开发问题
6

代表如何工作(在后台)?
How delegates work (in the background)?(代表如何工作(在后台)?)...
2023-11-11 C#/.NET开发问题
5

没有 EndInvoke 的 C# 异步调用?
C# Asynchronous call without EndInvoke?(没有 EndInvoke 的 C# 异步调用?)...
2023-11-11 C#/.NET开发问题
2

Delegate.CreateDelegate() 和泛型:错误绑定到目标方法
Delegate.CreateDelegate() and generics: Error binding to target method(Delegate.CreateDelegate() 和泛型:错误绑定到目标方法)...
2023-11-11 C#/.NET开发问题
14