1

I am working on a VB.Net application and recently installed Visual Studio Community Edition 2019 on my workstation. My development team is using Azure DevOps for version control. Whenever I clone the repository for the project at my new workstation, I am not able to run it, in Debug or Release mode, after making any changes. When I first load a branch, the project will run, but as soon as I make any code edits that are not just notes, or make any property changes in the visual designer, I get the error message. Oddly only a couple of weeks ago I was able to work on a new workstation with no issues.

I have tried uninstalling and reinstalling Visual Studio 2019 Community Edition, deleting and cloning the repo again, pushing changes and syncing them, checking "Use Managed Compatibility Mode" under Tools|->Options->Debugging->General, cleaning and rebuilding the project, Changing the Target CPU from AnyCPU to x86, to x64, and unchecking "Prefer 32-bit". None of that worked, the problem persists.

Below is a simple change that causes the error to occur (just an example, any edit seems to cause the error to occur) -

Original:

    TableLayoutPanel1.BackColor = MainAreas

    Label1.ForeColor = TextColor

Minor Edit:

    Dim thisVariable As String = ""

    TableLayoutPanel1.BackColor = MainAreas

    Label1.ForeColor = TextColor

I would expect to be able to edit a cloned repository and still be able to run it and/or debug it. But every edit from visual to code changes results in the error message described in the title - "Error while trying to run project: Unable to start program 'program_name.exe'. The request is not supported."

  • 1
    Have you checked to see if your Anti-Virus software is the issue? – TnTinMn Aug 23 '19 at 21:56
  • The application was getting flagged by MalwareBytes but the issue has since been resolved without making any changes there. I will keep an eye out if it happens again and see if that's part of the problem. – Zachary Marrs Aug 27 '19 at 15:17

1 Answers1

0

1.Do you use ConEmu in your machine which may affect the normal behavior?

If so, try Disable the Aggressive mode setting or go ConEmu → Settings → Integration → Default term → disable Force ConEmu as default terminal for console applications

2.Clear the cache of your VS2019, and restart vs to check if it helps. For VS2019, you should delete all ComponentModelCache folders under path C:\Users\current user\AppData\Local\Microsoft\VisualStudio\16.0_xxxxx.(If there're several 16.0_xxx folders, delete all the ComponentModelCache folders within them)

3.If the issue persists, please check whether your project builds normally. Try a rebuild before run the program, and make sure you've set the project as startup project. If the error still persists, check if the path in the error message is the same output path when you run a rebuild. (Check the Date Modified info to make sure it's exactly updated)

4.Check what's the result if your create a new vb.net project, same issue persists? Figure out whether this issue is about vs settings or only occurs in the project from azure devops.

About vs settings=> Try repair vs and disable third-party extensions

About the project itself=> Delete the .vs,bin and obj folders and restart vs.(Run vs as admin)

Hope it helps:)

LoLance
  • 25,666
  • 1
  • 39
  • 73
  • Thanks so much for your advice. After reinstalling VS2019 entirely twice, completely wiping the cache and getting the repository again, and changing "AnyPC" to "x64" the project is finally letting me save edits again. Unfortunately, I'm not sure which combination of those fixes finally did the trick, but I'm just glad it's working again. – Zachary Marrs Aug 27 '19 at 15:15
  • Glad to know your issue is now resolved :) It it happens again, feel free to let me know. – LoLance Aug 27 '19 at 15:35