Could not load type 'System.ServiceModel.Activation.HttpModule' from assembly 'System.ServiceModel

Nicolas Gago picture Nicolas Gago · Mar 28, 2013 · Viewed 118.6k times · Source

I'm running my Web Project in IIS.

It is a 4.0 Framework APP.

I have a Service.svc and I get this error when I run my Application.

"Could not load type 'System.ServiceModel.Activation.HttpModule' from assembly 'System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'"

I tried this --> aspnet_regiis.exe -iru which I found in a lot of forums and it didn't solve my problem.

Does anyone know another method ?

Answer

Kishan Zunjare picture Kishan Zunjare · Jul 24, 2013

Try with

c:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe -iru

When multiple versions of the .NET Framework are executing side-by-side on a single computer, the ASP.NET ISAPI version mapped to an ASP.NET application determines which version of the common language runtime (CLR) is used for the application.

Above command will Installs the version of ASP.NET that is associated with Aspnet_regiis.exe and only registers ASP.NET in IIS.

https://support.microsoft.com/en-us/help/2015129/error-message-after-you-install-the--net-framework-4-0-could-not-load