2

For some reason I can see docs only for .net libraries. Is there a way to see my own or third party docs in Visual studio?

I would like to know if its possible to see docs when pressing ctrl+space in Visual Studio 2010. Similar to what I'm used to in Eclipse :). Or at least when clicking (selecting) on method or class to be able to see docs in some kind of view (window)?

2 Answers 2

4
  1. Generate XML documentation by enabling the appropriate option in project's properties (Build tab)

  2. Put resulting XML file in the same folder as the DLL

3

By "docs" I assume you mean Intellisense tooltip? This tooltip will include XML documentation if that exists for the method. XML documentation in C# is described on MSDN. To add summary documentation to a method you add a special comment prefixed by ///:

public class Foo {

  /// <summary>
  ///   Bars the foo.
  /// </summary>
  public void Bar() {
  }

}

In VB.Net you can use the the same XML but will have to use ''' instead of /// as the special comment character.

You will have to compile the assembly using the /doc option. You can enable it in the project properties:

Enabling generation of XML documentation in project properties

The generated XML file should follow the assembly if you copy it to another location.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.