I’m currently learning C# through a beginner course provided by Microsoft. I followed the instructor's steps precisely, but I keep encountering an error.
Here are the steps I followed:
Created a new Console App using the command dotnet new console
inside Powershell.
Opened the project
in VS Code with code .
Installed the C# extension
.
Attempted to debug Program.cs
using the F5
key.
Despite following these steps, I keep receiving the error:
"No C# project is currently loaded. Please create a C# project in order to debug."
Do you have any ideas on how to resolve this issue?
After several attempts, I identified the issue. It turns out that the problem was due to the absence of the .vscode folder.
To resolve this, follow these steps to create the .vscode folder with the necessary launch.json and tasks.json files:
Press Shift + P and type .NET: Generate Assets for Building and Debugging
, then press Enter.
Press F5 to start debugging.
And just like that, you’re all set! Welcome to the world of debugging.