LinqToXSD and WPF appear to clash

Aug 25, 2010 at 1:03 AM

If you create a class library that contains both LinqToXsd schemas and WPF user controls, you get a CS0246 compiler error on the 'http' element of the LinqToXsd generated namespace when specifying it in a using statement. Seperating the LinqToXSD into a diferent assembly and referencing it resolves the problem.

The strange side-effect of trying to do this in a single assembly is that whilst you get CS0246 on the using statement, all type references resolve without error! It appears that there may be an underlying gremlin in the way in which the build occurs in this scenario.

I should mention that I've only tried this in VS2010 with .NET4 and the .NET4 build of LinqToXsd.