46
/// <summary>
/// This method does something...
/// </summary>
public void DoSomething() 
{
    // code...
}

When using that method/class etc... in a different .dll the comments do not show up.

Finglas
  • 15,518
  • 10
  • 56
  • 89

1 Answers1

61

A couple of suggestions:

  • Make sure that your compiler is configured to emit the XML doc comments as part of the compilation job
    • The Microsoft C# compiler switch that controls this is /doc, and can also be configured via the Build property page in a project's settings
  • Make sure that the XML file produced by the compiler matches the name of the DLL (i.e. myAssembly.dll -> myAssembly.xml)
  • When you use the assembly in another project, make sure that the XML file is in the same directory as the DLL being referenced.
Steve Guidi
  • 19,700
  • 9
  • 74
  • 90
  • Smashing - knew it was only something simple. I'd changed my bin folder location (instead of Visual Studio's horrible default location) but not done it for the xml comments. Cheers. – Finglas Oct 27 '09 at 19:05
  • 11
    I really don't understand why the people who wrote visual studio didn't set this as default. – Sweeper Jul 24 '15 at 08:50
  • This is working locally, the classLibProject.xml is appearing in my webapp's bin directory, and the file is getting used. however, when I deploy using Kudu's link directly to my git repo, the file is not appearing in the webapp's bin director like it does locally. what am i doing wrong?! – Nathan Tregillus Aug 04 '17 at 21:54