MVC Home

Dotnet Mvc















Examples
1> How to print HelloWorld in Mvc.
2>Database Connection using Entity FrameWork


What is MVC?



MVC is an architectural pattern which separates into different layer  i> Data access layer. 2> Bussiness layer 3> Presentation layer and It's divided  in three section:-





Here I am not gonna a  teach u.I can give u a basic ideas, how ASP.Net MVC  work.

Exam:-  How to print Hello World in MVC.

1. First step open visual studio .
    Here we used visual studio 2015

   Open the File-> click on New button-> finally click on Project option.
 

























Choose --> Web-> ASP.net WebApplication --> Name the project name according ur choise.
 I change the name to HelloWorld


























  Choose --> MVC-->Ok

>New project will open.
Click Right side -->Solution Explorer--> Controller->  1> HomeController-->
2> Add Viewbag.Message="HelloWorld"; inside Index ActionResult.


Go to Solution Explorer ->click View--> Home-->Index

Click run on Browser.


End...

Next Project How to Connect database using with an entity frame work with  LINQ .
.




Share this

First