Aspnetcore.dll failed to load. The data is the error

The Problem

When trying to locally debug a newly created solution within Visual Studio 2015 I encountered the below error when locally launching the application using IIS Express

A process with the ID of <id> is not running

Seeing no errors logged in the Visual Studio Output window, I checked the Windows Event Viewer and found the following error:

The Module DLL C:\Program Files (x86)\IIS Express\aspnetcore.dll failed to load. The data is the error.

The error was a bit confusing because it alluded to ASP.NET Core, even though I wasn’t using this in my project.

The Solution

It turns out that there was a reference to aspnetcore.dll within the below file within my solution

<SOLUTION_ROOT>\.vs\config\applicationhost.config

After commenting out the “AspNetCoreModule” entries I re-opened the solution within Visual Studio and the application launched without issue yay!

I’m not quite sure how the reference got there – I assume the original developer of the solution had been playing around with ASP.NET Core at some point in time?

Windows Event Viewer Screenshot

Shane Bartholomeusz

Shane Bartholomeusz

G’day, I’m a technical solutions consultant based in Perth, Australia that specialises in the Microsoft technology stack, including .NET, Dynamics 365, Azure and general web development etc.

This blog is my place to share my thoughts, helpful solutions and just random nerdy stuff.
Shane Bartholomeusz

Latest posts by Shane Bartholomeusz (see all)

Leave a Reply