Azure Functions vanishing into thin air

Have you ever developed Azure Functions and suddenly they vanished into this air?

Azure Functions

When you create Azure functions you can create functions in two different ways. You can edit the functions in Azure or you can create the functions in Visual Studio and deploy them to Azure. In this post I’m looking at both options and will described the situation I found myself in a while back when functions vanished into thin air.

First of all I’m going to have a look at the two different ways of creating functions.

Before  it is possible to create a function I need to create function app.

The Function App holds all the functions that you create.

Creating a Function in Azure Manually

You can create a new function by clicking on the plus sign next to the Functions section in your function app.

You then get a few options given to create  your functions. The In-Portal option is quite nice as you can type your functions and you can see what the functions do without having to refer back to your code.

Then you can select a template

In my case I selected the Webhook option and my function is ready to run. I can call this function from my favourite workflow engine, Microsoft Flow.

Ready to have a look at the other deployment options

Deploying a function to Azure with Visual Studio

It is also possible to publish your Functions to Azure using Visual Studio. This helps if you want to debug some code. You can simply set breakpoints and run the function like you would do with any other code in Visual Studio.

Imagine if you created some Functions in your Function app and you decide to create your next function in Visual Studio.

Great Idea? We will find out!

The steps in Visual Studio are.

Create a new project.

Select the template

Admire the code generated for you.

Now you can publish your function to azure functions.

Now you can publish your function to Azure:

When you click on Ok, you will get a big clue!

The delete existing files is set to true by default. So that when you create all your functions there is no mess left behind from previous versions. A good idea! But if you created some functions in a different way or different project before they will also be removed.

You can change this is the profile settings for your connection by deselecting the Remove additional files at destination setting.

Share
Pieter Veenstra

Business Applications Microsoft MVP working as the Head of Power Platform at Vantage 365. You can contact me using contact@sharepains.com

Recent Posts

Introducing 8 AI Functions for Dataverse in Power Apps

Recently Microsoft added AI Functions to Dataverse that can be used in Power Apps. In…

13 hours ago

Copy and paste Scope steps in the new Power Automate Designer

One of the outstanding issues with the new Power Automate Designer is Copy and Paste…

1 week ago

Receive the available storage within your SharePoint Online tenant

Within the SharePoint admin centre there is that little detailed overview, telling you the available…

4 weeks ago

Options for Documenting Your Power Apps: Comments, Code, and Controls

Within Power Apps there are various ways to document your app. In this post I'm…

1 month ago

2 ways to duplicate SharePoint Lists to support your Power Apps

Recently I've been asked quite a few times to duplicate SharePoint lists as part of…

1 month ago

Update a Hyperlink Column in SharePoint with Power Automate

Today, I was asked about how to create a lookup to a document or item…

1 month ago