Asp.net MVC3.0 Getting Started Guide 1. Introduction

Source: Internet
Author: User

Introduction 

This tutorial teaches you how to use Microsoft Visual Web Developer 2010 Express Service Pack 1

//: Visual Studio in the free version

Create an ASP. net mvc web page program. Can I use aspx? Appid = VWD2010SP1Pack "> Web Platform Installer installation.

 

Before you start, make sure that your machine has installed the following essential components:

· Visual Studio Web Developer Express SP1 prerequisites

// Note: We recommend that you use Visual Studio 2010 + sp1

· ASP. net mvc 3 Tools Update

· SQL Server Compact 4.0 (runtime + tools support)

//: SQL Server7, SQL Server2000, SQL Server2005, and SQL Server2008 are also supported.

 

If you are using Visual Studio 2010 instead of Visual Web Developer 2010,

To install required components, click the following link: Visual Studio 2010 prerequisites.

 

What to create

You will complete a simple movie list program that supports creating, editing, and displaying movie lists from the database.

Below are two program screenshots. It includes a list page showing all movies:

This program also allows you to add, edit, and delete movies, and view details of a movie.

All data inputs contain verification to ensure that the data stored in the database is correct.

 

Skills you will learn

The learned skills are as follows:

  • How to create an ASP. net mvc Project
  • How to create an ASP. net mvc controller and view
  • How to use the Code First of the object framework to create a new database
  • How to obtain and display data
  • How to edit and verify data

Start

Open Visual Studio 2010 and select new project on the launch page.

Visual Studio is an integrated development environment.

 

Create your first application

You can use Visual Basic or C # To create applications for programming languages.

Select Visual C # on the left and then selectASP. net mvc 3 Web Application. Name the project as "MvcMovie ",

Click OK.

In the New ASP. net mvc 3 Project window that appears, select Internet Application.

Make sure to Use HTML5 markup and retain Razor as the default view engine.

Click OK. The ASP. net mvc program you just created, Visual Studio uses the default template,

Therefore, you have completed an application that can work without doing any work.

This is a simple "Hello World !" Program, which is a good place for you to start the application.

Select "start debugging" from the "debug" menu"

You can also use the shortcut key F5 to start debugging.

 

Visual Studio starts a browser and opens the main page of the program. Note that the address bar displays localhost instead

Such as example.com. This is because localhost always points to your local computer. In this case, it points

The application you have created. When Visual Studio starts a network project, a random port is used by the web server.

As shown in, this is a random number of 43246. When you run the program, you may see a different port.

Next section: Controller

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.