Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

Question:

Is there a way to add a hyperlink to an ObsoleteAttribute's message such that it is clickable in Visual Studio's IntelliSense tooltip?

Background:

I know that for XML documentation comments, you can do something like this:

public void Main()
{
    MethodWithHyperlinkInXmlDocsIntelliSense();
}

/// <summary>
/// This is a math function I found. <see href="http://stackoverflow.com">HERE</see>
/// </summary>
public void MethodWithHyperlinkInXmlDocsIntelliSense()
{
}

enter image description here

However, neither of the below options show the hyperlink as clickable in Visual Studio 2019 (16.8.3) IntelliSense tooltips.

[Obsolete("This is a math function I found. <see href="http://stackoverflow.com">HERE</see>")]

enter image description here

[Obsolete("This is a math function I found. See http://stackoverflow.com")]

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
659 views
Welcome To Ask or Share your Answers For Others

1 Answer

Actually, IntelliSense tooltips for ObsoleteAttribute class does not support hyperlink as XML document comments. I have tested it several times.

So to help improve this ticket, I reported the issue on our DC Forum.

You can vote it and add any comments if I did not describe the issue in detail so that it will get more Microsoft's attention. And I hope the Team will give you a satisfactory reply.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...