简体   繁体   English

Viewengine是否不在asp.net mvc3升级中查看区域?

[英]Viewengine not looking into areas for views in asp.net mvc3 upgrade?

i'm upgrading my asp.net mvc app to the MVC 3 from mvc 2. I had everything set up so that there were no areas, but now i have to move the old application into its own area so i can start a new one. 我正在将我的asp.net mvc应用程序从mvc 2升级到MVC3。我已经进行了所有设置,以便没有任何区域,但是现在我必须将旧应用程序移至其自己的区域,以便可以启动一个新的应用程序。 。 The new area is working great, but for some reason, when i try to go into the area where the old app was, it looks for the views to be in the views folder in the root of the app, instead of in the views folder in the area. 新区域运行良好,但是由于某些原因,当我尝试进入旧应用程序所在的区域时,它会将视图查找在应用程序根目录下的views文件夹中,而不是在views文件夹中在那地区。 any thoughts? 有什么想法吗?

原来我的问题是因为我使用的初始路由注册来自静态路由表集合,而不是上下文对象传递到区域注册中。

您可能会遇到以下帖子中更详细描述的问题: http : //blogs.msdn.com/b/marcinon/archive/2010/11/14/mvc-areas-and-multiple-view- engines.aspx

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM