How to define programming language for the `<code>` element

269 Views Asked by At

How do I define programming language for the <code> element in XmlDocs?

I'm having XML examples, but they are highlighted as C# (since it's a C# project).

Example:

/// <code>
/// <![CDATA[
/// <SaveConfig>
///         <File>Web.config</File>
///         <File>App.config</File>
/// </SaveConfig>
/// ]]>
/// </code>
/// </example>
1

There are 1 best solutions below

1
On BEST ANSWER

Use the lang attribute of <code> tag. For example:

<code lang="C#"></code>
<code lang="VB"></code>