I am stuck with one asp.net error. My application work fine on development and test environemnt. But on production it give me following error:
Could not load file or assembly 'someProject' or one of its dependencies. Access is denied.
In summary if you get the "Could not load file or assembly error", this means that either your projects or their references were built with a reference to a specific version of an assembly which is missing from your bin directory or GAC.
This error usually means that the assembly was not found. Try verifying that the file exists in the directory where your application is running.
Restart Visual Studio, clean and build a solution. Remove the class library references and add it again. Tools > Import and Export Settings Wizard > Reset all settings (maybe some setting was not well configured).
Go to Sysinternals and download Process Monitor: http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx
Then start it up, filter thread and registry actions away. Clear contents. Run your app and get the error, and then stop the collection in process monitor. Now search for an ACCESS DENIED status, and you'll be able to see the exact file that's causing troubles, as well as the user account trying to get access.
Just delete the bin folder and then agian copy it. Now, it is working...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With