Multiple views on a single MVC ASP.NET page

I want to display different Views on the same page in ASP.NET MVC technology. How can this be achieved.

I have data coming from two different tables, and for this I have 2 different Views to display. How to display both of these views on the same page.

Is there a concept for the View view in the MVC view? Or are there some provisions for creating a main view that can contain multiple views.?

+5
source share
3 answers

ASP.NET MVC " " , . "" , .

:

-

+1

Yes, aspx web forms have a main page, and then you use custom .ascx controls.

With MVC, the "main page" is by default under the symbol

Views\Shared\_Layout.cshtml  

Now you can also use Twitter’s wonderful bootloader and really start creating more user-friendly layouts with easy-to-use css, etc.

Your controller may return

PartialViewResult

as mentioned by other answers of others, these links should help you.

+1
source

All Articles