如何为CHM或HTML文件生成C#文档?

Bru*_*oLM 8 c# visual-studio-2010 xml-documentation

有没有办法直接从Visual Studio中的代码文档生成可读文档文件?(也考虑2010年)

代码示例:

/// <summary>
/// Convert a number to string
/// </summary>
/// <param name="number">An integer number to be converted to string</param>
/// <returns>Number as string</returns>
/// <example>
/// <code>
///     var s = MyMethod(5);
/// </code>
/// </example>
/// <exception cref="Exception">In case it can't convert</exception>
/// <remarks>
/// Whatever
/// </remarks>
public string MyMethod(int number)
{
    return number.ToString();
}
Run Code Online (Sandbox Code Playgroud)

Fer*_*ndo 9

使用DocProject.它可以创建HTML文档以及CHM.你应该先安装Sandcastle.


Pet*_*cej 4

VSdocman可以直接从 Visual Studio 执行此操作。