Fog Creek Software
Discussion Board

Welcome! and rules

Joel on Software

Counting LOC in VS.NET


Anyone know of a way to count the lines of code on a per-project basis in Visual Studio.NET?

I apoligize in advance if this turns out to be a RTFM question, but I haven't been able to locate any info.


Jeff MacDonald
Monday, February 24, 2003

Would you settle for a free add-in?

Mike Gunderloy
Monday, February 24, 2003

Done deal.  Thanks, Mike.


Jeff MacDonald
Monday, February 24, 2003

I really think that, especially in the .net epoch, couting lines doesn't mean very much.  Do you count all lines, or only non-generated ones? 

Brady Kelly
Thursday, February 27, 2003

In VB, use lots of properties.  Type in the first line, hit Enter, and voila!  Five bonus lines!  I can't stand myself, I'm so productive!

Friday, February 28, 2003

I'd say what's needed is a utility that can count lines of code in specific regions, or ignore specific regions.  That way the LOC util can ignore "Windows Form Designer generated code" sections.

Jim Harshaw
Wednesday, March 5, 2003

Even better is getting a job somewhere that isn't so stupid to want to count Lines of Code. :)

Brad (
Sunday, March 9, 2003

*  Recent Topics

*  Fog Creek Home