Click to Rate and Give Feedback
MSDN
MSDN Library
Visual Studio 2005
Visual Studio
Visual C#
This page is specific to
Microsoft Visual Studio 2005/.NET Framework 2.0

Other versions are also available for the following:
C# Programming Guide
XML Documentation Comments (C# Programming Guide)

In Visual C# you can create documentation for your code by including XML tags in special comment fields in your source code directly before the code block they refer to. For example:

/// <summary>
///  This class performs an important function.
/// </summary>
public class MyClass{}

When you compile with /doc the compiler will search for all XML tags in your source code and create an XML documentation file.

NoteNote

The XML doc comments are not metadata; they are not included in the compiled assembly and therefore they are not accessible through reflection.

In This Section

Related Sections

C# Language Specification

For more information, see the following sections in the C# Language Specification:

  • Appendix A Documentation Comments

See Also

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Documenting /// comments      Anand Raman - MSFT   |   Edit   |  

Several customers have asked how Microsoft creates our API docs internally and what tools we use. Microsoft uses Sandcastle to ship the API content to MSDN.

Sandcastle enables managed class library developers throughout the world to easily create accurate, informative documentation with a common look and feel. Internally we use Sandcastle to ship .NET Framework documentation and also documentation to http://silverlight.net/quickstarts/ and http://ajax.asp.net/docs/

Sandcastle Highlights:

  • Produces quality, comprehensive, familiar MSDN-like documentation.
  • Works with or without authored comments.
  • Supports Generics and .NET Framework 1.x, 2.x and 3.x
  • Sandcastle has 2 main components (MrefBuilder and Build Assembler)
  • MrefBuilder generates reflection xml file for Build Assembler
  • Build Assembler includes syntax generation, transformation..etc
  • Sandcastle is used internally to build .Net Framework documentation

Sandcastle Architecture:

Please see the post at http://blogs.msdn.com/sandcastle/archive/2006/07/28/681209.aspx

Sandcastle wiki site
www.sandcastledocs.com. On this web site, you can find links to the following information:

  • Where to get Sandcastle
  • Sandcastle GUI's
  • Scripts and Automation
  • Sandcastle Tips and Tricks
  • Sandcastle FAQs
  • Sandcastle Questions

Sandcastle Blogs:

http://blogs.msdn.com/sandcastle

Anand..

Tags What's this?: Add a tag
Flag as ContentBug
Processing
© 2008 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker