My friend is starting to learn C# using Visual Studio 2015 and I'm helping him. After we wrote a simple hello world console application (below) it did not run at all.
static void Main(string[] args)
{
Console.WriteLine("Hi World");
Console.ReadKey(false);
}
After I click the run button, it began to show diagnostic diagrams for a couple of seconds, but after that, exited the execution without showing console. I looked up at output window and I saw this error:
The Program 'loblobloblob' Has Exited With Code -1073740771 (0xc000041d).
What might be the cause of this?
There is nothing wrong with the code you posted.
Ensure that your Program.cs
looks as follows:
using System;
namespace MyFirstProgram
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello, World!");
Console.ReadKey(false);
}
}
}
If this doesn't work, there is something wrong with your VS2015 installation.
User contributions licensed under CC BY-SA 3.0