NewLine in object summary
Greetings
When setting a summary for a property / field / method etc.. is it possible to have a newline in it?
/// <summary>
/// This is line 1
/// This is line 2
/// </summary>
public bool TestLine { get; set; }
When I set this it shows as on mouse over:
bool TestLine This is line 1 This is line 2
But I want it to show as:
bool TestLine This is line 1 This is line 2
I've tried using \n
but that doesn't work. Is there any way to get this done?
Solution 1:
You want to use some thing like this
/// <summary>
/// Your Main comment
/// <para>This is line 1</para>
/// <para>This is line 2</para>
/// </summary>
public bool TestLine { get; set; }
Solution 2:
This may be an old thread but I was searching for an anwser while using Visual Studio 2019. I wanted paragraph and lines breaks. The following works well for me:
/// <summary>
/// <para>parameter name="guidType" options:</para>
/// <br>0 = SequentialAsString</br>
/// <br>1 = SequentialAsBinary</br>
/// <br>2 = SequentialAtEnd</br>
/// </summary>
Produces the following:
parameter name="guidType" options:
0 = SequentialAsString
1 = SequentialAsBinary
2 = SequentialAtEnd