Click here to Skip to main content
15,884,425 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How do I use two views from different controllers in the same view in MVC?
I have two different views one is partial view and the other one is not a partial view and I have to use them together in a new View how can i do that?
Posted
Updated 30-Sep-14 20:55pm
v2
Comments
Sinisa Hajnal 30-Sep-14 6:56am    
Not sure if you can use full view within another. Try with RenderAction("ViewName", "Controller") - this is normally used for Partial Views that do not bind to current view model...

I moved the partial view to the shared view folder so I was able to call it in the full view and got it
 
Share this answer
 
Yes here RenderAction () can be a solution if none of the controller's Action method' s views have the layout. In simple words the views need to have layout = null;
Hope you get the point.
Thanks
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900