使 XML 文档引用类的字段

Але*_* Д. 5 c#

如何从XML注释中引用UpdateChanged字段Long1

public sealed class SystemConfiguration
{
    public long Long1;

    /// <summary>
    /// Make reference to Long1
    /// </summary>
    public bool UpdateChanged;
}
Run Code Online (Sandbox Code Playgroud)

Joã*_*elo 5

您可以使用<see cref="SystemConfiguration.Long1"/>

Visual Studio 生成一个 XML 文档文件,其中为每个成员分配了一个唯一的 ID。您可以在以下位置查看 ID 生成规则:

处理 XML 文件

在这种情况下,将生成的完整 ID 是F:YourNamespace.SystemConfiguration.Long1。不过,您可以使用较短的版本,因为您在同一班级。