This site is where I will attempt to explain basic to intermediate concepts in C# programming through Visual Studio.
Before you go any further, download and install Visual Studio Express 2013 for Windows.
To begin a new project in Visual Studio (for our tutorial purposes), follow these steps:
- File -> New -> Project
- Select Console Application
- Choose Name, Location, and click OK.
Your screen should look similar to the following (I’m utilizing Visual Studio Ultimate 2013):
For our first exercise (before we delve into really explaining anything), we’re going to perform the essential “Hello World!” first program. Enter the following lines of code between the brackets following the static void Main(string[] args) line until the entire program looks like so:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace HelloWorld
{
class Program
{
static void Main(string[] args)
{
System.Console.WriteLine("Hello World!");
System.Console.ReadLine();
}
}
}
Once complete, hit the start button (or hit F5 to compile the program). If everything is set up correctly, you should be greeted with a console window that states, “Hello World!”
