MVC MCQ

MVC MCQ | Freshers & Experienced

  • Sharad Jaiswal
  • 17th Jun, 2021

We have listed here the Best MVC MCQ Questions for your basic knowledge of MVC (Model View Controller). This MVC MCQ Test contains 30+ MVC Multiple Choice Questions. You have to select the right answer to every question.

Practice Best MVC MCQ Questions:

1) MVC stand for:

  • A. Model-View-Controller.
  • B.Modern-View-Controller.
  • C.Model-View-Constant.
  • D.None of these

2) Who developed MVC?

  • A. Leonhard Euler
  • B.Amedeo Avogadro
  • C.TrygveReenskaug
  • D.None of these

3) MVC comes from which year?

  • A. 2003
  • B.2002
  • C.2004
  • D.2006

4) What is the best approach to assign a session in MVC?

  • A. Session["LoginID"] =7;
  • B.System.Web.HttpContext..Current.Session["LoginID"] =7;
  • C.Current.Session["LoginID"] =7;
  • D.None of these

5) Is ASPX View Engine faster than Razor View Engine?

  • A. Yes
  • B.No
  • D.None of the abov

6) RedirectToAction() Method for which Status code represents?

  • A. 302
  • B.305
  • C.300
  • D.301

7) Which Namespaces are required to Data Annotation using MVC?

  • A. System.ComponentModel.DataAnnotations
  • B.System.ComponentModel
  • C.Both 1 and 2
  • D.None of these

8) What do you mean by ActionResult() ?

  • A. It is an abstract Class
  • B.It is a Concrete Class
  • C.Both 1 and 2
  • D.None of the above

9) What do you mean by ViewResult() ?

  • A. It is an abstract Class
  • B.It is a Concrete Class
  • C.Both 1 and 2
  • D.None of the above

10) Can we use view state in MVC ?

  • A. Yes
  • B.No
  • C.Both 1 and 2
  • D.None of these

11) Which of the following DRY principle in ASP.Net ?

  • A. Don't revise yourself.
  • B.Don't repeat yourself
  • C.Both 1 and 2
  • D.None of these

12) How can you comment using Razor Syntax?

  • A. *@ Comment me @*
  • B.@* Comment me @*
  • C.*@ Comment me *@
  • D.@* Comment me *@

13) return View() works like in ASP.Net MVC C# as

  • A. Response.Redirect()
  • B.Server.Transfer()
  • C.Both 1 and 2
  • D.None of these

14) Can you point your browser to a view and have it render?

  • A. Yes
  • B.No

15) Choose the return types of a controller action method?

  • A. ViewResult
  • B.JavaScriptResult
  • C.RedirectResult
  • D.All of the above

16) Can we do validation in MVC using data annotations?

  • A. Yes
  • B.No

17) Can it possible to share a view across multiple controllers?

  • A. Yes
  • B.No

18) Identify the MVC view engine?

  • A. Razor
  • B.Shaft
  • C.Blade
  • D.Edge

19) Is controller responsible for providing the user interface (UI) to the user?

  • A. Yes
  • B.False

20) Can view data be accessed via the ViewBag property?

  • A. Yes
  • B.No

21) Term in the MVC architecture that receives events is called

  • A. Transmitter
  • B.Modulator
  • C.Controller
  • D.Receiver

22) In the model-view-controller (MVC) architecture, the model defines the

  • A. Presentation layer
  • B.Interface layer
  • C.Business-logic layer
  • D.Data-access layer

23) MVC is composed of three components these are

  • A. Model View Controller
  • B.Model Variable Centered
  • C.Member Vertical Controller
  • D.Member Vertical Controller

24) What is the extension of mvc view when using C#?

  • A. cshtml
  • B.vbhtml
  • C.None of the above
  • D.All of the Above

25) Which namespace is used for aspx view engine?

  • A. System.Web.Razor
  • B.System.Web.Mvc.WebFormViewEngine
  • C.Both A & B
  • D.None of the above

26) Which of the following view file types are supported in MVC?

  • A. .aspx
  • B..cshtml
  • C..vbhtml
  • D.All of the Above

27) What is true about viewbag in mvc?

  • A. It is used to transfer temporary data from the controller to the view.
  • B.ViewBag only transfers data from controller to view
  • C.ViewBag values will be null if redirection occurs.
  • D.All of the above

28) In mvc jsp acts as a ................

  • A. View
  • B.Model
  • C.Controller
  • D.None of the above

29) What is the use of controller in mvc?

  • A. It is responsible for controlling the flow of the application execution
  • B.It is responsible for controlling the application logic
  • C.It receives an input from the users via the View, then processes the user's data
  • D.All of the above

30) What is the name of default viewstart page in asp.net mvc?

  • A. _Login.cshtml
  • B._Layout.cshtml
  • C._ViewStart.cshtml
  • D._ViewStart.cshtml

Leave A Comment :

Valid name is required.

Valid name is required.

Valid email id is required.