• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.
  • The forums have been upgraded with support for dark mode. By default it will follow the setting on your system/browser. You may override it by scrolling to the end of the page and clicking the gears icon.

How do I make a C# Console app build and debug in Visual Studio Code?

Joined
Apr 2, 2008
Messages
22 (0.00/day)
How do I make a C# Console app build and debug in Visual Studio Code?

I have already built my C# Console App in Visual Studio Code. The issue I have is when I reopen the folder where the project file is in Visual Studio Code and then rebuilding the code and debugging it again.

Here is what I do and what happens. After I open the folder where the project file resides, I click on this to process the code to debug:

07.png

And then I click on the appearing "Run and Debug" button

08.png

But then the bottom status bar says "Looking for CSS classes in the workspace..." followed by a percentage in paragraphs. Why is this? Why does this happen when there are no CSS classes at all and my project is a C# project?

09.png

Why is this? This is just a brief snapshot of some difficulties I find when I reopen a project after I have closed Visual Studio Code. I have experienced other errors and problems in building and running my code.

To continue, in order to deal with the project as a solution, I click on this icon to open the solution panel.

10.png

This seemingly allows me to view the solution. As the following view appears, I click on the project.cs file and attempt a debugging session from there.

11...png

With this file being displayed, I clicked on the menu option, Run -> Start Debugging

12...png

Then, at this point, in the pop up option window that appears in the middle and top of the development environment, I pick "C#":

13...png

Something went wrong and in the bottom right of my IDE, I get this message:

14.png

Please advise. What should I do now?
 
What extensions do you have installed? Maybe try disabling them. To me this seems like some kind of extension interference.
 
I'm pretty sure it's some issue with your extensions.
The question is: why use VS Code, and not go straight to Visual Studio IDE? No need to bother with random extensions and deal with misconfiguration etc.
VS code is a fancy notepad that tries to be a "jack of all trades" IDE. Never really got into it, specifically because of all these issues. Basically if I need a programming notepad - I use notepad++ on windows, or gedit (or whatever's default on my system ATM) on linux.
If I need an IDE - I just use an IDE.
 
I'm pretty sure it's some issue with your extensions.
The question is: why use VS Code, and not go straight to Visual Studio IDE? No need to bother with random extensions and deal with misconfiguration etc.
VS code is a fancy notepad that tries to be a "jack of all trades" IDE. Never really got into it, specifically because of all these issues. Basically if I need a programming notepad - I use notepad++ on windows, or gedit (or whatever's default on my system ATM) on linux.
If I need an IDE - I just use an IDE.
I concur. The full Visual Studio is the right tool for the job.
 
Back
Top