This project has moved and is read-only. For the latest updates, please go here.

Referencing Topics from API

Topics: User Forum
Jan 8, 2009 at 1:05 AM
I have a C# library with all of its documentation nested inside the code files. Is there a way for the documentation generated out of this to reference SHFB topic files? For example, I'd like to go through my project and add links to conceptual topics using the <seeAlso> tags.

Jan 8, 2009 at 3:04 AM
For MAML topics, use an anchor tag that uses the topic's unique ID and a ".htm" extension.  For example:

/// See the <a href="bd1ddb51-1c4f-434f-bb1a-ce2135d3a909.htm">Control Tutorial</a> for more information.

For additional content (other HTML or .topic files added as content to the project), just substitute an appropriate path to the file.  For those, you also need to add a relative path.  For example:

/// See <a href="..\Links.html">Links to Resource</a> or <a href="..\OtherStuff\Related.html">Related Items</a>.

Mar 19, 2009 at 8:44 PM
Hmm.. I did

/// <seealso href="aaa.. .htm">LinkText</seealso>

on a type to reference into conceptual content. I got a link, but when I clicked it I got an external instance of the Internet Explorer rather than a content jump in the help viewer. How can you link from API doc out to conceptual pages from WITHIN the help viewer?

Mar 19, 2009 at 9:05 PM
you have to use <a href="a.. .htm">...</a> and not the <see> or <seealso> tags. I ran into that same thing when experimenting with the tags one day.
Mar 19, 2009 at 9:06 PM
So how do you get the link into the See Also section of the generated help page?
Mar 20, 2009 at 3:00 AM
Edited Mar 20, 2009 at 3:04 AM
I'd forgotten about href support on see/seealso.  You should be able to add a target="_self" attribute to the <seealso href=""> or <see href=""> tag to get it to open in the same window.  However, I'm not sure how well that will work for the website output.