Routing and GetVirtualPath problem

柔情痞子 提交于 2020-03-05 07:56:19

问题


I'm using MVC 2 Preview2, with two areas in a single project. When I use RouteTable.Routes.GetVirtualPath(this.viewContext.RequestContext, null) from inside an area, I got the virtual path to the first area instead. Except for this, areas are working pretty well.

What can I doing wrong?


回答1:


in MVC 2 use GetVirtualPathForArea instead of GetVirtualPath



来源:https://stackoverflow.com/questions/1627423/routing-and-getvirtualpath-problem

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!