I have a bizarre problem with a Visual Studio project. I’m writing a C# application using the .Net 4 framework. I add a reference to some DLLs (which I believe are compiled in 3.5) and they work until I build the solution. When this happens, it removes the References in the sense that the compiler cannot see the namespaces within these DLLs. Any ideas?
The error:
Error 4 The type or namespace name ‘XXX’ could not be found (are you
missing a using directive or an assembly reference?)
I have managed to resolve this problem. I checked the
Project Propertiesand found that it was using.Net 4 Client Profilerather than the.Net 4 Fullframework. Changing this to the full version has resolved my problem. I believe the problem is caused due to the lack of theSystem.Webnamespace within theClient Profile.