"System cannot find the file specified" when adding a new Azure IoT Edge module in Visual Studio

0

I've followed these steps exactly and am getting the error below:

  1. Select File > New > Project...
  2. In the new project window, search for IoT Edge and choose the Azure IoT Edge (Windows amd64) project. Click Next.
  3. In the configure your new project window, rename the project and solution to something descriptive like CSharpTutorialApp. Click Create to create the project.
  4. In the Add Module window, configure your project with the following values:
  5. Select Add to create the module.

I get this error regardless of the combination of solution folders, module names, and any other parameters that I enter during this workflow:

The system cannot find the file specified. (Exception from HRESULT: 0x80070002)

The net result is that no changes are made to the solution -- no IoT Edge module project is created, no other files are altered.

I've tried running Visual Studio 2019 (16.4.3) as administrator, uninstalling and reinstalling the Azure IoT Edge Tools extension, all without success.

What can I do to troubleshoot this further?

Update 1: I've double-checked all documented prerequisites and still have this issue.

  • Visual Studio 2019 16.4.3, all prerequisite Visual Studio workloads installed
  • .NET Core workload installed the latest -- 3.1 LTS SDK -- only. Is there a hidden dependency on a specific older .NET Core 2.x SDK somewhere? Or is the documentation for VS Code on the subject out of date? (I'm using VS but was looking everywhere to see if I had missed anything)
  • Git for Windows installed (via Visual Studio Installer)
  • Docker Windows Desktop installed & switched to Windows containers
  • Azure IoT Edge Tools for VS 2019 installed (and uninstalled & reinstalled)
  • no UNC/FQ paths in the item or project template locations:
    • C:\Users\larsk\OneDrive\Documents\Visual Studio 2019\Templates\ProjectTemplates
    • C:\Users\larsk\OneDrive\Documents\Visual Studio 2019\Templates\ItemTemplates
  • multiple reboots
  • this is on a machine that just recently got the latest (1909) version of Win10 Pro reinstalled on it.

Update 2: Updating to Visual Studio 2019 16.4.4 did not help either.

visual-studio-2019
azure-iot-edge
azure-iot-sdk
asked on Stack Overflow Jan 30, 2020 by Lars Kemmann • edited Jan 31, 2020 by Lars Kemmann

1 Answer

1

The solution turned out to be running a Repair operation through the Visual Studio Installer.

answered on Stack Overflow Jan 31, 2020 by Lars Kemmann

User contributions licensed under CC BY-SA 3.0