Why doesn't intellisense show comments?

B

Brett Romero

I've added comments to a method in A.dll. B.exe references A.dll. I
see the new method and only the stock comment (type methodname()) in
intellisense. However, when I use object browser from B.exe to view
A.dll, I see the new method and all the comments. How do I get the
comments to come through in B.exe via intellisense when I scroll to
that method?

Thanks,
Brett
 
J

jeremiah johnson

Brett said:
I've added comments to a method in A.dll. B.exe references A.dll. I
see the new method and only the stock comment (type methodname()) in
intellisense. However, when I use object browser from B.exe to view
A.dll, I see the new method and all the comments. How do I get the
comments to come through in B.exe via intellisense when I scroll to
that method?

Thanks,
Brett

Sounds like you're looking for XML comments, which can show you
descriptions of constructors and properties and methods and whatnot.

If that's what you're talking about, read this:
http://msdn.microsoft.com/library/d.../csref/html/vcwlkXMLDocumentationTutorial.asp

if that gets chopped, here's a tinyurl.com shortcut:
http://tinyurl.com/fba68
 
V

Vijay

I followed the MSDN article and I get the comments on my intellisense.. Can
you post your comment structure for a specific method in A.dll

" .. The <summary> tag is used by IntelliSense inside Visual Studio to
display additional information about a type or member. .."

VJ
 
B

Brett Romero

As an example, one of the methods follows this structure:

/// <summary>
/// Description for SomeMethod.</summary>
/// <param name="s"> Parameter description for s goes here</param>
public void SomeMethod(string s)
{
}

In B.exe, I don't see the description or summary. All I see in
intellisense is:

void SomeMethod(string s)

Brett
 
F

Frans Bouma [C# MVP]

Brett said:
I've added comments to a method in A.dll. B.exe references A.dll. I
see the new method and only the stock comment (type methodname()) in
intellisense. However, when I use object browser from B.exe to view
A.dll, I see the new method and all the comments. How do I get the
comments to come through in B.exe via intellisense when I scroll to
that method?

You've to export the xml comments from A.dll at compile time to a.xml.
Then you've to make sure that a.xml is in the same folder as the
referenced a.dll. When you then open B and recompile, you'll see that
the comments of A will show up in vs.net.

FB

--
------------------------------------------------------------------------
Lead developer of LLBLGen Pro, the productive O/R mapper for .NET
LLBLGen Pro website: http://www.llblgen.com
My .NET blog: http://weblogs.asp.net/fbouma
Microsoft MVP (C#)
------------------------------------------------------------------------
 
B

Brett Romero

The XML code comment file is in the bin/debug folder, same as A.PDB and
A.DLL. After compiling B.exe, I still do not see the comments from
A.DLL.

Brett
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top