views:

1725

answers:

8

In C# documentation tags allow you to produce output similar to MSDN. What are a list of allowable tags for use inside the /// (triple slash) comment area above classes, methods, and properties?

+1  A: 

MSDN article from 2002 detailing all the tags and when to use them:

http://msdn.microsoft.com/en-us/magazine/cc302121.aspx

Ian Nelson
+1  A: 

Check out http://thoughtpad.net/alan-dean/cs-xml-documentation.html. Great documentation on the various C# XML documentation tags. (Go to the bottom to see the tags)

David Mohundro
Alas, the domain has expired and this is a broken link.
Mike Post
Well that stinks - Google cache still has it, but for how long, who knows?
David Mohundro
A: 

See the excellent MSDN article here as your first stop.

Jesse C. Slicer
+1  A: 

GhostDoc helps by creating a stub comment for your method/class.

Forgotten Semicolon
+2  A: 

If you type this just above a method or class, intellisense should prompt you with a list of available tags:

/// <
Joel Coehoorn
+3  A: 

Here's a list:

  • summary
  • param
  • returns
  • example
  • code
  • see
  • seealso
  • list
  • value
  • author
  • file
  • copyright

Here's an example:

<file>
<copyright>(c) Extreme Designers Inc. 2008.</copyright>
<author>Kevin Driedger</author>
<datecreated>2008-09-15</datecreated>
<summary>
Here's my summary
</summary>
<remarks>
<para>The <see cref="TextReader"/> can be used in the following ways:
<list type="number">
<item>first item</item>
<item>second item</item>
</list>
</remarks>
<example>
<code>
System.Console.WriteLine("Hello, World");
</code>
</example>
<param name="aParam">My first param</param>
<returns>an object that represents a summary</returns>
</file>
Kevin Driedger
There is no author tag for the c#
Nassign
A: 

Look inside the docs for Sandcastle. This is the new documentation standard for .NET.

Penguinix