Hi,
I have a question concerning the class generation in Visual Studio 2008.
I use a web service which is added using Add Web Reference. It works great and all the classes seem to have been generated successfully. When I try to generate a class diagram using View Class Diagram for the project which uses the web service, I get:
Some of the selected type(s) cannot be added to the class diagram. Check the code for errors and ensure that all required assemblies are referenced
I have followed both of these suggestions, and the project has no errors or warnings. I get no error for other projects in the same solution which do not use any web service.
The web service http://foo.bar.com/wsdl/ in a bit anonymized form (though it still has the same structure, I just changed some names) can be found here if it is important for the answer: http://pastebin.com/rd7W9BA6
Append
- As an example if I double left-click on class Age inside the WebService folder (in the tree) in Class View I get to see the public partial class Age in the file Reference.cs.
- I can see the above Age class in Object browser as well.
It really seems like I have all the necessary information to build a class diagram. But when I right click on said class and choose View Class Diagram I get the error message quoted above.
If I right click any other class, which is not in the WebService folder, and choose View Class Diagram I get to see the diagram for the clicked class. So it must have something to do with it being generated from a WSDL-file.