Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7587865
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T19:46:54+00:00 2026-05-30T19:46:54+00:00

Our current project is written in ASP.NET MVC 1 using mvc-turbines (and unity) for

  • 0

Our current project is written in ASP.NET MVC 1 using mvc-turbines (and unity) for IOC/DI.

When I try to start the application from 2008 everything works fine, but from 2010 I keep getting the “No parameterless constructor”-error.

Why?
Both are targeting the same .Net framework. The VS 2010 solution keeps using the default controller factory. Any suggestions to debug this?

[MissingMethodException: No parameterless constructor defined for this object.]
   System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandle& ctor, Boolean& bNeedSecurityCheck) +0
   System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean fillCache) +86
   System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) +230
   System.Activator.CreateInstance(Type type, Boolean nonPublic) +67
   System.Web.Mvc.DefaultControllerFactory.GetControllerInstance(RequestContext requestContext, Type controllerType) +80

[InvalidOperationException: An error occurred when trying to create a controller of type 'CommonProject.Web.Shared.Controllers.MyController'. Make sure that the controller has a parameterless public constructor.]
   System.Web.Mvc.DefaultControllerFactory.GetControllerInstance(RequestContext requestContext, Type controllerType) +190
   System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName) +68
   System.Web.Mvc.MvcHandler.ProcessRequestInit(HttpContextBase httpContext, IController& controller, IControllerFactory& factory) +118
   System.Web.Mvc.MvcHandler.ProcessRequest(HttpContextBase httpContext) +46
   System.Web.Mvc.MvcHandler.ProcessRequest(HttpContext httpContext) +57
   System.Web.Mvc.MvcHandler.System.Web.IHttpHandler.ProcessRequest(HttpContext httpContext) +7
   System.Web.Mvc.MvcHttpHandler.VerifyAndProcessRequest(IHttpHandler httpHandler, HttpContextBase httpContext) +61
   System.Web.Routing.UrlRoutingHandler.ProcessRequest(HttpContextBase httpContext) +111
   System.Web.Routing.UrlRoutingHandler.ProcessRequest(HttpContext httpContext) +40
   System.Web.Routing.UrlRoutingHandler.System.Web.IHttpHandler.ProcessRequest(HttpContext context) +7
   CommonProject.Web._Default.Page_Load(Object sender, EventArgs e) in 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T19:46:56+00:00Added an answer on May 30, 2026 at 7:46 pm

    I am assuming that in the Application_Start() method of your HttpApplication (Global.asax.cs) you are setting the controller factory to be your custom controller factory.

    I believe what is happening is that prior to this line of code executing, an exception is being thrown somewhere in Application_Start(). If this happens, any subsequent call to the web application will bypass this exception, which can result in your application misbehaving (such as not using your custom controller factory).

    I would debug Application_Start() and make sure it is executing correctly. If you’re using ELMAH, then the exception should get logged.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my current project we are testing our ASP.NET GUI using WatiN and Mbunit
in our current project we are using ADO.NET Entity Framework as data layer for
On our current WPF project, we've been performing dependency injection using the Ninject IOC
We are trying to use the MVP pattern in our current project (asp.net app)
So while we're using foreign keys in our current project, I've heard the argument
Our current MVC project is set up to have ViewModels that encapsulate the data
For the current project we're using JSR-303 annotations to validate our interface parameters. I
For our current project we are required to scan QR-codes via our own application.
Our current project does not use Hibernate (for various reasons) and we are using
I have isolated very strange bug from our current project: index.html (demo) and iframe.html

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.