XML in an XML Documentation Comment (C#)

How can I embed XML in an C# XML documentation comment (e.g. in an header of a method)?

Answers


Put it in a CDATA section, and put the CDATA section inside a <code> element so it will be formatted correctly:

/// <example>
/// <code>
/// <![CDATA[ 
/// <someXml>
///     ...
/// </someXml>
/// ]]>
/// </code>
/// </example>

Press '/' (slash) 3 times in the code file and it will open a code summary section. You can paste your xml on that section.


Need Your Help

Prevent SQL injection without using cfqueryparam

coldfusion sql-injection

I have old projects containing a lot of queries which are not using cfqueryparam to prevent SQL injection. Is there any way to use some function to do similar on Application level on each form fiel...