The type or namespace name "Syndication" does not exist in the namespace "System.ServiceModel". After upgrading to VS2010

I am getting the following error when trying to compile my asp.net site after upgrading the project from vs2008 to vs2010

The type or namespace name "Syndication" does not exist in the namespace "System.ServiceModel" (are you missing an assembly reference?)

I have an asp.net site targeting 3.5 (as in vs2008) I also added a link to System.ServiceModel.Web

I also have these instructions at the top of my class: using System.ServiceModel; using System.ServiceModel.Description; using System.ServiceModel.Syndication; using System.ServiceModel.Web;

The last 2 are complaining about the above error, commenting them throws errors (can't find WebGet, etc.) like flipflops.

Does anyone have any ideas?

+2


a source to share


5 answers


remembered some similar thing in the past, I fixed it by continuously changing the target between 2,3,3,5 until it worked - yes, you heard me correctly. My guess is that it took a time or two to fix the config file from one version to the next.



+1


a source


I got this working in .NET 3.5 by adding a web DLL, thanks to the post below.

DOTNET 3.5: Add reference to System.ServiceModel.Web.dll



DOTNET 4.0: Add reference to System.ServiceModel.dll

fooobar.com/questions/2579640 / ...

+9


a source


For me it turned out to be the following line:

<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">

      

he should have been

<assemblyBinding appliesTo="v2.0.50727" xmlns="urn:schemas-microsoft-com:asm.v1">

      

I had many other projects in solutions based on the same - not sure how it went missing, but adding it to the problem.

+3


a source


Try to remove any references in question and then re-add and re-compile them. Is it the same?

+2


a source


If you get this in Visual Studio 2010, I found I cleaned up your solution by closing Visual Studio and restarting it resolving the intellisense issue.

+1


a source







All Articles