Multiple types were found that match the controller named…

Multiple types were found that match the controller named ‘Home’. This can happen if the route that services this request…

Multiple types were found that match the controller named ‘Home’. 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.

 

Şeklinde bir hata almanız halinde projenizdeki RouteConfig içerisinde aşağıdaki gibi bir controller adresi belirtmeyle sorunu düzeltebilirsiniz.

routes.MapRoute("Default", "{controller}/{action}/{id}",
new
{
controller = "Home",
action = "Index",
id = UrlParameter.Optional
}, new[] { "NameSpaceiniz.Controllers" });

Bu kadar basit. İyi çalışmalar…

0 0 vote
Article Rating
Share this Story

Related Posts

Subscribe
Bildir
guest
0 Yorum
Inline Feedbacks
View all comments

Sponsor Bağlantılar

Sponsor Bağlantılar