Dear Sir,
Can you explain MVC pattern one submit button how work
explain step by step
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
SIVAPosted Dec 23, 2011, 5:42 AM
Hi Manuel,
MVC is a design pattern to develop the ASP .Net web applications.
its the shorter form of Model View Controller
MVC defines as follows
" The pattern isolates "domain logic"(the application login for the user) from the user interface (input and presentation), permitting independent development,testing and maintenance of each"
According to MVC a program should be written in 3layers
Model: it represents the type that we want to access
View: which provides I/O to user
Controller: its the most important, which is responsible for handling all the tasks of application..
How MVC application will work
step1 : incoming request directed to controller
step2: controller process request and forms a datamodel
step3: model is passed to the view
step4: view transforms model into appropriate format
step5: reponse is rendered
Sample application :
pre requirements :
Visual studio 2010 with its service pack1
install the MVC3 template
start the VS & select the ASP .Net MVC3 application template
go to Controller folder--> right click and add a new controller
write this method inside of the controller public string Welcome(string s){ return "Welcome "+s;}
right click on this method & select add view option to select the view & design the view according to ur wish
go to the browser http://localhost/controllername/welcome?s=CSharpCorner
now see the result
I hope you will satitsfy with this please reply me if you have any updates
Satyapriya NayakPosted Dec 12, 2011, 5:46 AM
Please refer Our recommended articles
Thanks