I’m having a problem with a project in Visual Studio 2010 after moving to a new corporate issued Windows 7 machine (from an aging XP machine).
I copied my projects across to the new machine, but Visual Studio seems to be having problems loading the WPF designer. I have a solution that includes several projects, it builds fine and runs fine, but when I try to open a WPF window in the designer, I get a whole bunch of error messages along the lines of:
"unable to load the metadata for assembly 'Foo'. This assembly may have been
downloaded from the web. See http://go.microsoft.com/fwlink/?LinkId=179545.
The following error was encountered during load: Could not load file or assembly
'Foo, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its
dependencies. The system cannot find the file specified."
(Note the link in the error message seems to be no use whatsoever)
I think the problem here is that my corporate IT people have set up Windows 7 machines such that “My Documents” is actually a network drive that is cached locally. This is not a bad thing, because now all my files are backed up whenever I’m on the corporate network, but I think it’s upsetting Visual Studio.
Is there a solution to this that doesn’t involve abandoning the synched network drive (which I like) and copying everything to the local hard drive (which puts backups back on me).
The solution found here on stackoverflow:
Unable to view designer in VS2010 due to DLL over the network
worked for me. Same problem working in corporate environment, instead of on my own machine.