Monday, 15 August 2016

Welcome to ASP.NET Core 1.0 MVC

Let’s create our first ASP.NET Core MVC Web Application. We assume that we already have Visual Studio 2015 Update 3 and .NET Core 1.0.0 - VS 2015 Tooling Preview 2. If you have not installed .NET Core yet then I may recommend you to follow our initial discussion How to install .NET Core 1.0. Alternatively you can follow Microsoft Official Site directly.

Create a new Solution

  • Open Visual Studio 2015.
  • Open New Project Screen through menu File >> New >> Project.
  • Select Blank Solution through Installed >> Templates >> Other Projects >> Visual Studio Solutions.
  • Name solution as “ASP.NET Core”. Set suitable location as “C:\ASP.NET Core\Welcome To .NET Core 1.0\”.
  • Click OK Button.

Add a new ASP.NET Core Project in Solution

  • Open New Project Screen through Solution Context Menu >> Add >> New Project Or File >> New >> Project.
  • Select ASP.NET Core Web Application (.NET Core) through Installed >> Templates >> Visual C# >> .NET Core.
  • Name project as “WebApplicationCore.NetCore”.
  • Set suitable location as “C:\ASP.NET Core\Welcome To .NET Core 1.0\ ASP.NET Core” (it is default location depending on solution path).
  • Click OK Button.
  • Select “Web Application” template from Template Window. And leave other options unchanged.
  • Click OK Button.
  • It will create new ASP.NET Core MVC Web Application.

Run Application in Debug Mode

  • Press F5 or Debug Menu >> Start Debugging or Start IIS Express Button on Toolbar to start application in debugging mode.
  • It will show Home Page in browser.
  • Click About Menu Item to open About page.
  • Click Contact Menu Item to open Contact Page.

Sample Source Code

We have placed sample code for this session in "Welcome to ASP.NET Core_Code.zip" in https://aspdotnetcore.codeplex.com/SourceControl/latest CodePlex repository.

No comments:

Post a Comment