Question

I am trying to get VB.NET XML Comments to work with IntelliSense, and maybe it doesn't work the way I think it does.

    ''' <summary>
    ''' Gets or sets the Patient Code.
    ''' <list type="bullet">
    ''' <listheader><description>Validation:</description></listheader>
    ''' <item><description>Field Required</description></item>
    ''' <item><description>Field Max Length: 25</description></item>
    ''' </list>
    ''' </summary>
    ''' <value>The region reference key.</value>

This should, when you are typing in a function, display the "Get or sets the Patient Code" then below that, it should display a list of bulleted items with "Validation:" as the header?

alt text http://www.codejames.com/errored.jpg

Maybe I am doing it wrong, but it doesn't seem to be working correctly.

Was it helpful?

Solution

You are not doing this incorrectly, it's just simply not supported. While the HTML markups may appear in the output of some tools, IntelliSense is not one of them.

IntelliSense is a textual display in Visual Studio 2008 and we do not support displaying many / most of the markups as they should appear in an HTML style display. Instead we tend to strip out the markup tags that are not supported and display the resulting text.

OTHER TIPS

You can "fake" it (without the numbers) by surrounding the <description> contents with the <para> tag -- this will at least show up in Intellisense nicely spaced, but without the appropriate list delimiter (bullet, number).

<summary>
Gets or sets the Patient Code.
<list type="bullet">
<listheader><description>Validation:</description></listheader>
<item><description>Field Required</description></item>
<item><description>Field Max Length: 25</description></item>
</list>
</summary>
<value>The region reference key.</value>

If you don't care all that much about the generated output, just add your bullet in each line:

<item><description><para>* Field Required</para></description></item>

See also <list> XML Documentation

Update

Since posting this, VS2012 11.0.60610.01 Update 3 seems to have added formatting support, so you no longer need the <para> internal wrapping or adding your own bullets.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top