Visual Studio build failing and not showing any error

Viewed 1384

I have created simple Console.WriteLine function, on building it says build failed. But doesnt show any error / warning

enter image description here

enter image description here

3 Answers

In my case I fixed this by restarting my PC

Check your build output. Sometimes you will have information about the error in the output. example: enter image description here

Program class should be declared as public

public class Program
{
    public static void Main()
    {
        Console.WriteLine(1);
    }
}
Related