Quantcast
Channel: Everything SharePoint and XAML » SPErrors
Viewing all articles
Browse latest Browse all 10

Error Compiling Old Visual Studio Project

$
0
0

So I had one of those idiot moments. I am preparing for a SharePoint 2007 Development training class I am giving next week. I was attempting to compile a Visual Studio project that defined my web part definitions. I received the following error when I attempted to compile the application. I was referencing the Microsoft.SharePoint assembly correctly.

The type or namespace name ‘SharePoint’ does not exist in the namespace ‘Microsoft’ (are you missing an assembly reference?)

This particular project had not been compiled since before SP2 was released. I am sure you can see where this is going. Anyway, after pulling my hair out for 30 minutes, I soon realized my mistake. Since the project was last compiled prior to SP2, the target framework was still set back to “.NET Framework 2.0”. Setting the target framework to “.NET Framework 3.0” resolved my issue.



Viewing all articles
Browse latest Browse all 10

Trending Articles