Search code examples
c#xmlsandcastle

How can I reference a Members page from a <seealso> tag?


I'm generating some XML documentation that I am in turn building into a help file (.chm) via Sandcastle.

However, I'm being tripped up on how to link to the Members page for a given class. What I mean by that is say for example, I have a class named Class1 with various methods and properties. I can link to the class itself via <seealso> in the following way:

/// <seealso cref="Class1">Class1</seealso>

Is there a way to use the cref attribute to instead bring me to the page displaying all members of the class, and not the class itself? I didn't find any documentation on either the <see>, <seealso>, or cref pages on MSDN.

Basically, I was looking for something like the following (which clearly isn't working):

/// <seealso cref="Class1.Members">Class1 Members</seealso>

I have tried a few variations on that line, which at best, are best guesses at what it could actually be, but my searches/tries haven't proven very helpful. Is this even possible?


Solution

  • After some more digging, I found what I was looking for:

    First, I made sure the Topic file naming method in Sandcastle was set to "Member name".
    Second, the see/seealso tags had to be formatted in the following way:

    /// <seealso href="AllMembers_T_MyNamespace_Class1.htm" target="_self">Class1 Members</seealso>  
    

    The name for the href attribute can be found by right clicking in the desired page and view in the "Properties" of the page.

    The target="_self" is required for the linked topic to open in the same help file, otherwise it opens in a browser window.