I installed NuGet into Visual Web Developer 2010 Express, but when I go to Solution Explorer, right-click on a project's "References" folder, and select "Add Library Package Reference", I immediately get this error:
Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
There's just an OK button, and no way for me to retrieve the additional information it's telling me about.
This is a fresh install of NuGet; I've never installed it on this computer before.
How can I fix and/or diagnose this error so I can get NuGet to work?
It turns out this error occurs when PowerShell is not installed. In trying to further diagnose the problem, I went to Tools > Library Package Manager > Package Manager Console, and the console came up with red text that said:
Error: The Package Manager Console requires PowerShell 2.0 runtime, which is not detected on this machine. Please install the PowerShell 2.0 from http://support.microsoft.com/kb/968929 and restart Visual Studio.
After I installed PowerShell, the Add Library Package Reference dialog started working.
I've filed a bug report against NuGet, asking for a better error message when prerequisites are missing (and ideally for the installer to actually install the prerequisites): Item #530: "Unable to load one or more of the requested types" error
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