Hi,
I have added a new entity to Nop solution version 3.4, added new classes in Core,Data and services.
Also, I added new controller in admin and web named WarrantyController in order to handle CRUD operations.
Locally on my machine it worked very well. but when i deployed the dlls to the live server. it gives me the error
System.InvalidOperationException: An error occurred when trying to create a controller of type 'Nop.Admin.Controllers.WarrantyController'. Make sure that the controller has a parameterless public constructor. ---> Autofac.Core.DependencyResolutionException: An exception was thrown while invoking the constructor 'Void .ctor(Nop.Services.Payments.IPaymentService, Nop.Services.Shipping.IShippingService, Nop.Services.Orders.IShoppingCartService, Nop.Services.Directory.ICurrencyService, Nop.Services.Directory.IMeasureService, Nop.Services.Customers.ICustomerService, Nop.Services.Seo.IUrlRecordService, Nop.Core.IWebHelper, Nop.Core.Domain.Directory.CurrencySettings, Nop.Core.Domain.Directory.MeasureSettings, Nop.Services.Helpers.IDateTimeHelper, Nop.Services.Localization.ILanguageService, Nop.Core.IWorkContext, Nop.Core.IStoreContext, Nop.Services.Security.IPermissionService, Nop.Services.Localization.ILocalizationService, Nop.Services.Common.ISearchTermService, Nop.Services.Stores.IStoreService, Nop.Core.Domain.Catalog.CatalogSettings, System.Web.HttpContextBase)' on type 'WarrantyController'. ---> Object reference not set to an instance of an object. (See inner exception for details.) ---> System.NullReferenceException: Object reference not set to an instance of an object. at Nop.Admin.Controllers.WarrantyController..ctor(IPaymentService paymentService, IShippingService shippingService, IShoppingCartService shoppingCartService, ICurrencyService currencyService, IMeasureService measureService, ICustomerService customerService, IUrlRecordService urlRecordService, IWebHelper webHelper, CurrencySettings currencySettings, MeasureSettings measureSettings, IDateTimeHelper dateTimeHelper, ILanguageService languageService, IWorkContext workContext, IStoreContext storeContext, IPermissionService permissionService, ILocalizationService localizationService, ISearchTermService searchTermService, IStoreService storeService, CatalogSettings catalogSettings, HttpContextBase httpContext) at lambda_method(Closure , Object[] ) at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate() --- End of inner exception stack trace --- at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate() at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters) at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters) at Autofac.Core.Resolving.InstanceLookup.Execute() at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, IComponentRegistration registration, IEnumerable`1 parameters) at Autofac.Core.Activators.Delegate.DelegateActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters) at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters) at Autofac.Core.Resolving.InstanceLookup.Execute() at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, IComponentRegistration registration, IEnumerable`1 parameters) at Autofac.Core.Resolving.ResolveOperation.Execute(IComponentRegistration registration, IEnumerable`1 parameters) at Autofac.ResolutionExtensions.ResolveOptionalService(IComponentContext context, Service service, IEnumerable`1 parameters) at System.Web.Mvc.DefaultControllerFactory.DefaultControllerActivator.Create(RequestContext requestContext, Type controllerType) --- End of inner exception stack trace --- at System.Web.Mvc.DefaultControllerFactory.DefaultControllerActivator.Create(RequestContext requestContext, Type controllerType) at System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName) at System.Web.Mvc.MvcHandler.ProcessRequestInit(HttpContextBase httpContext, IController& controller, IControllerFactory& factory) at System.Web.Mvc.MvcHandler.BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, Object state) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
I spent a lot of time on this but no luck!!
Would you please help me.
Thanks