Address Book MVC
Address Book MVC
Address Book MVC
Prerequisites:
1. Must have Microsoft visual studio2010 installed on your machine.
2. Must Have Microsoft Sql server 2008 installed on your machine.
3. To build an ASP.NET MVC 3.0 application, you need either of the following:
If you have nothing, please visit http://www.asp.net/mvc and download and install Visual Web
Developer Express 2010.
If you already have Visual Studio 2010, please visit http://www.microsoft.com/enus/download/details.asp?id=1491 and download the standalone installation for ASP.NET MVC.
4. To build as ASP.NET4.0 application you just need to install VS.NET 2012.
Project Details
Application Type: Web
Startup window: Login page
Implementation: MVC
Database: MSSQL
Framework: 4.0
Language: c#
Credentials:
Name: Admin
Password: Admin
Contents:
This AddressBookMVC will contain following files.
1. AddressBookMVC Project
2. Sql server query file.
Description of contents:
1. AddressBookMVC: This folder will have solution file, controllers, models and view required to operate the
program.
Deccansoft Software Services |
Modules:
Login
User
Admin
Step 2:
Click Next button.
Step 3:
If required database is not there then click on New Connection button, then it creates new window in that we
need to specify the database server name and select the database name from drop down list the press OK
button.
Step 4:
Click on Next button.
Step 5:
Select the tables, views and stored procedures which are required and press Finish button.
10
Step 6:
It creates an entity as below.
11
In Web.config
It automatically add the connection string
<Configuration>
<connectionStrings>
<add name="AddressBookMVCEntities"
connectionString="metadata=res://*/AddressBookMVC.csdl|res://*/AddressBookMVC.ssdl|res://*/AddressBookM
VC.msl;provider=System.Data.SqlClient;provider connection string="Data Source=.\sqlexpress;Initial
Catalog=AddressBookMVC;Integrated Security=True;MultipleActiveResultSets=True""
providerName="System.Data.EntityClient" />
</connectionStrings>
12
13
14
15
Click Create
16
17
18
Step 7: Click Edit link (Refer step 5) Modify Country Details Click Save
19
Step 8: Click Delete link (Refer step 5) Delete Country Details Click Delete
20
21
Step 10: Click on country name link for creating or editing state details.
22
23
24
Step 13: Click Edit link (Refer step 11)Edit the details Click Save / Back to Manage States in India.
25
Step 14: Click Delete link (Refer step 11) click Delete / Back to Manage States in India.
26
27
Step 16: Click on link click Register (Refer step 4) Enter user detailsClick OK.
28
29
30
31
Step 20: Click Edit link (Refer step 18) Edit details click Save / Back to list link.
32
Step 2 1: Click Delete link (Refer step 18) click Delete clicks Delete / Back to list link.
33