Mohsen Afshin
Mohsen Afshin

Reputation: 13436

Strange '`'.dll file in bin folder, ASP.Net MVC

Recently when I build and publish my MVC4 project a strange file appear in my bin folder and I encounter the following error while browsing the website:

Could not load file or assembly '`' or on of the its dependencies. An attempt was made to load a program with an incorrect format.

enter image description here

The website works well on the local IIS with the existence of these files.

When I delete these two files on either local or production server, it says:

Could not load type "XXXX.MvcApplication"

What can cause this?

Upvotes: 4

Views: 334

Answers (1)

Amir
Amir

Reputation: 788

Go to your project properties(Right click on project and hit properties) and in Application tab change your Assembly name from "`" to the on you expected your dll name should be.

Upvotes: 2

Related Questions