|
An easy way to generate documentation for classes, methods, interfaces,…
from XML comments using visual studio .net is:
1. Type 3 slashes “///” in the line proceeding the method and visual studio will
directly generate the most important XML Comments tags for you.
2. These are the summary, parameters list, and return value. You may add extra
tags as remarks, example, code,...etc.
3. Before you build your project right click on its name in the solution
explorer and choose “properties”, then click on “Build” tab.
4. Check on the XML Documentation File checkbox to tell Visual Studio to
generate an XML documentation file.
5. Add this style sheet
file to the output directory.
6. Open the XML documentation file and add the following line after the first
list to tell the XML fileto look for and use the XSL style sheet file:
7. Now if you open the
XML documentation file with your web browser, it will show
the documentation in a readable format:
References:
http://www.codeproject.com/KB/XML/XMLDocStylesheet.aspx
|