Reputation: 1726
I am trying to find a way to put carriage returns/new lines in the xml comments of my properties. Right now, when the tip appears in intellisense, the line are all bunched up, making it hard to read:
I'd like it to look like this:
Here's what the xml looks like:
///<summary>
///Question:
/// 'Are you sure you wish to delete the selected |Value|'
///<para>Replace |Value| with the entity name of choice.</para>
///</summary>
internal const string ConfirmEntityDelete = "Are you sure you wish to delete the selected |Value|?";
I understand that xml doesn't recognize whitespace so I can't use empty <para>
tags. The only way I've had any luck is by using the para tags with a period <para>.</para>
. It is visible in the tip but at least it makes it a tad more readable.
I've looked here http://msdn.microsoft.com/en-us/library/5ast78ax(v=vs.110).aspx and found all the tags that can be used, and have tried them all, but haven't had any luck.
Any help is greatly appreciated!
Upvotes: 5
Views: 7239
Reputation: 2337
Maybe something like this? It adds a carriage return but not an empty line though.
/// <summary>
/// Your main comment
/// <para> </para>
/// <para>The rest of the comment</para>
/// </summary>
public void CommentMethod()
{
}
EDIT: Found and added character to display new line. I knew I had done something similar before.
Upvotes: 8