Adding Comments in C# Code
You can easily add comments within the structure of your C# code and view them by using code comment Web reports. Comments and XML tags displayed in a code comment Web report are prefaced with the comment syntax ///. Typically, comments are entered before user-defined types such as a class, struct, or interface; members such as a field, event, property, or method; or a namespace declaration.To add comments in C# code
Open a .cs file in an editor.
Switch to Code view.
Enter /// followed by any XML tags or text strings. If you enter /// on the line before the definition, the editor creates a template of a documentation comment and fills in the parameters and other information.
For example, in the file class1.cs before public Class1() you could enter the following:
///
///summary description
///
///
///This is a test.
///
In the code structure for the Class1, the information listed within the


0 comments:
Post a Comment