Solved

/// <summary></summary> by default please

Posted on 2011-02-24
5
408 Views
Last Modified: 2012-06-27
I'm using VS 2010, and the default for adding the XML comments are like this:
/// <summary>
///
/// </summary>

I would like them to default to this:
/// <summary></summary>

manually setting this is not the end of the world, but it does get tedious.

Reason for this preference:
 - When you minimize the XML Comments, it reduces to this:
/// <summary> [...]
 - If it is on one line, you get it to minimize to this:
/// <summary>Used to process data :(</summary> [...]

0
Comment
Question by:hpdvs2
  • 3
5 Comments
 
LVL 3

Expert Comment

by:kraiven
ID: 34971990
If you're happy to lose all of the automatically produced parameter and return values that the expanded comment gives you then I would suggest writing your own code snippet. It's really easy and would give you exactly the functionality you want.

See http://msdn.microsoft.com/en-us/library/ms165394%28VS.80%29.aspx
0
 
LVL 8

Author Comment

by:hpdvs2
ID: 34972154
While that does provide a partial solution, the key purpose of this is to reduce some of the overhead while still allowing the minimized XML comment to be easily read.

In my opinion, having to rewrite the additional comments portions would require more work than altering the initial line.

Thanks.
0
 
LVL 11

Accepted Solution

by:
Sudhakar Pulivarthi earned 500 total points
ID: 34978510
Hi,
It is good to use GhostDoc Plugin for VS 2010/2005 which writes the standard comments automatically. quite interesting one!!!
U can download it from below link.
http://submain.com/download/ghostdoc/
0
 
LVL 8

Author Comment

by:hpdvs2
ID: 34980375
Sudhakar, your answer worked.  I was able to use to free edition to do this.  One additional note, by default, Ghost doc is not setup like this.  I had to go in to the Tools=>Ghost Doc=>Options, then from the Ghost doc config window, select the "Options" tab, and check "Keep single line...";
0
 
LVL 8

Author Closing Comment

by:hpdvs2
ID: 34980389
Just adding this line, to get this behavior out of the program, you need to go in to the menu Tools=>Ghost Doc=>Options, then from the Ghost doc config window, select the "Options" tab, and check "Keep single line...";
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Article by: Ivo
C# And Nullable Types Since 2.0 C# has Nullable(T) Generic Structure. The idea behind is to allow value type objects to have null values just like reference types have. This concerns scenarios where not all data sources have values (like a databa…
Introduction Although it is an old technology, serial ports are still being used by many hardware manufacturers. If you develop applications in C#, Microsoft .NET framework has SerialPort class to communicate with the serial ports.  I needed to…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now