.Net Interview Questions and Answers

Search:

Explain Areas in MVC?( MVC interview questions with answers)

By : Shiv Prasad Koirala | Jan 17th, 2014 | Views : 4030 | Comments : 0 Bookmark and Share

This question is taken from book .NET interview question published by BPB publications http://www.flipkart.com/net-interview-questions-6th/p/itmdyuqzdqx8cvqx .  


In case you are new to MVC you can start with www.questpond.com MVC videos from here http://www.youtube.com/watch?v=KAKxm4eQP24


Areas help you to group functionalities in to independent modules thus making your project more organized. For example in the below MVC project we have four controller classes and as time passes by if more controller classes are added it will be difficult to manage. In bigger projects you will end up with 100's of controller classes making life hell for maintenance.



If we can group controller classes in to logical section like "Invoicing" and "Accounting" that would make life easier and that's what "Area" are meant to.



You can add an area by right clicking on the MVC solution and clicking on "Area" menu as shown in the below figure.



In the below image we have two "Areas" created "Account" and "Invoicing" and in that I have put the respective controllers. You can see how the project is looking more organized as compared to the previous state.



Recently one of our readers who had gone for TCS India for interview for MVC position was asked to explain difference between viewdata,viewbag,tempdata and session.


Below is a video created by www.questpond.com which explains the same in more detail.


 
Rate this Article :
1 Star
2 Stars
3 Stars
4 Stars
5 Stars
1 1 1 2 1
 
 
 
 

.NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala

In this article we will explain .NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala.... Read More

Explain MVC application life cycle?

In this article we will explain MVC application life cycle.For more articles and videos visit us on www.questpond.com... Read More

What is the difference between Stored Procedures and Function (SQL Server interview question with answers)?

In this article we will explain what is the difference between Stored Procedures and Function.For more articles and videos visit us on www.questpond.com... Read More

C# Design pattern interview questions with answers: - How Singleton is different from Static class?

In this article we will explain How Singleton is different from Static class.... Read More

WCF interview questions and answers: - What is the difference between Service endpoint and Client endpoint?

In this article we will explain What is the difference between Service endpoint and Client endpoint.... Read More

.NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala

In this article we will explain .NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala.... Read More

Explain MVC application life cycle?

In this article we will explain MVC application life cycle.For more articles and videos visit us on www.questpond.com... Read More

What is the difference between Stored Procedures and Function (SQL Server interview question with answers)?

In this article we will explain what is the difference between Stored Procedures and Function.For more articles and videos visit us on www.questpond.com... Read More

C# Design pattern interview questions with answers: - How Singleton is different from Static class?

In this article we will explain How Singleton is different from Static class.... Read More

WCF interview questions and answers: - What is the difference between Service endpoint and Client endpoint?

In this article we will explain What is the difference between Service endpoint and Client endpoint.... Read More

Article Categories

Learn in Hindi