4
 public class TestClass
        {
            /// <summary>
            /// Do my work
            /// </summary>
            /// <exception cref="ArgumentNullException">This is a Description</exception>
            public static void DoWork()
            {
                //do my work
            }
        }
TestClass.DoWork();

How do I display text "This is a description" in "Quick Info" when I hover over a method?

Test class picture

Test class call picture

ch t
  • 51
  • 1
  • Does this answer your question? [XML Comments - Exceptions not showing in intellisense](https://stackoverflow.com/questions/33813808/xml-comments-exceptions-not-showing-in-intellisense) and [In C# XML Documentation, only the summary tag is working](https://stackoverflow.com/questions/57833812/in-c-sharp-xml-documentation-only-the-summary-tag-is-working) –  Jun 12 '21 at 08:24

2 Answers2

0

You could try the following comment to get what you wanted.

public class TestClass
    {
        /// <summary>
        /// Do my work
        /// </summary>
        /// <exception cref="This is description"></exception> 
        public static void DoWork()
        {
            //do my work
        }
    }

Result:

enter image description here

Jack J Jun
  • 5,633
  • 1
  • 9
  • 27
0

This feature isn't implemented yet. https://github.com/dotnet/roslyn/issues/1515

For now you can duplicate this info into summary tag.