method descriptions

R

rodchar

hey all,
how do you get a description to show up for methods?
for instance,
when you type

class1.loadRow(

and then the methods parms show up, how do you get a description to show up
here?

thanks,
rodchar
 
J

Jon Skeet [C# MVP]

rodchar said:
how do you get a description to show up for methods?
for instance,
when you type

class1.loadRow(

and then the methods parms show up, how do you get a description to show up
here?

You need to provide XML documentation for your methods, for instance:

/// <summary>
/// Writes the current status to the log file.
/// </summary>
public void LogStatus()
{
....
}

Look up "XML documentation" in the index of MSDN for more information.
 
R

rodchar

this works for me when referring to methods in the same class, however when i
try to reference this class from a code-behind the description doesn't show
up?

rod.
 
J

Jon Skeet [C# MVP]

rodchar said:
this works for me when referring to methods in the same class, however when i
try to reference this class from a code-behind the description doesn't show
up?

Is the class in the same solution? If it is, and if the project is
being referenced directly, Visual Studio should just cope with it. If
you're referring to it as a DLL, you should tell Visual Studio to build
an XML documentation file with the same name as the class library (but
with .XML on the end instead), and in the same directory. When you add
the reference to the DLL, Visual Studio will notice that there's an
appropriate XML file present and use it.
 
R

rodchar

thanks for the help jon,
rod.

Jon Skeet said:
Is the class in the same solution? If it is, and if the project is
being referenced directly, Visual Studio should just cope with it. If
you're referring to it as a DLL, you should tell Visual Studio to build
an XML documentation file with the same name as the class library (but
with .XML on the end instead), and in the same directory. When you add
the reference to the DLL, Visual Studio will notice that there's an
appropriate XML file present and use it.
 

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