开发者

MVC 3 finds same controller twice?

开发者 https://www.devze.com 2023-04-08 04:32 出处:网络
I am working on an application in C# using MVC 3 that has areas in it, and when I attempt to debug, I get the following error:

I am working on an application in C# using MVC 3 that has areas in it, and when I attempt to debug, I get the following error:

Multiple types were found that match the controller nam开发者_如何学JAVAed 'Access'.

This can happen if the route that services this request ('{controller}/{action}/{id}') does not specify namespaces to search for a controller that matches the request. If this is the case, register this route by calling an overload of the 'MapRoute' method that takes a 'namespaces' parameter.

The request for 'Access' has found the following matching controllers: 

FARM.Shared.Controllers.AccessController FARM.Shared.Controllers.AccessController

There is only one controller with that name, so why is it listing the same controller twice, and how do I fix it?

0

精彩评论

暂无评论...
验证码 换一张
取 消