CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Jan 2001
    Posts
    4

    How to count the total number of code lines in a VB.NET project?

    As the title says, is there a convenient way to count how many lines of code in a VB.NET project? Thanks for help.

  2. #2
    Join Date
    May 2004
    Posts
    17

    count lines

    hi
    It is not the strait forward but
    save the*.vb as *.txt
    open it in word
    go to file > properties> statistic and see the line #

    * it will count remarks also
    roni

  3. #3
    Join Date
    Jun 2003
    Location
    Lahore
    Posts
    31

    Lines of Code

    First of all delete spaces between the lines of codes, then write every code line on individual line. then at the status bar you can see the line numbers where your cursor will be. Reach at the end of the line and in this way you can see the number of lines in your code.

    Best of luck
    Asad Naeem
    May Allah keep this world Peaceful. (Aameen)

  4. #4
    Join Date
    Apr 2004
    Location
    Oregon, USA
    Posts
    40
    Now what's the purpose for knowing how many lines of code you have?

    If you have a lot more code for the same project, then that would actually show more less skill at programming than the person that did the same project with less code. Also comments & white space really differs, because like I use a lot of comments & white space, so competing against me..I'd be champion of the world programmer!

  5. #5
    Join Date
    Sep 2001
    Location
    Montreal Canada
    Posts
    1,080
    Hum for you less code means you're a better programmer ?

    I think that you're mistaken there.

    My code might be more voluminous because I do more validations and also because I might put more comments.

    I might also make my code more General ( meaning I use parameters and the like ) so I don't have to rewrite it, which might also make my project Bigger (and in that case you need to validate the parameters )

    Does that mean I'm a worse programmer ? if so then you're mistaken.
    Nicolas Bohemier

  6. #6
    Join Date
    Feb 2000
    Location
    OH - USA
    Posts
    1,892
    It's about time we got some energy in the VB.NET forum!

    I've attached an app that should do everything you need, but if not, it's pretty easy to modify.


    ps. UI of the year!
    Attached Files Attached Files
    Good Luck,
    Craig - CRG IT Solutions - Microsoft Gold Partner

    -My posts after 08/2015 = .NET 4.x and Visual Studio 2015
    -My posts after 11/2011 = .NET 4.x and Visual Studio 2012
    -My posts after 02/2010 = .NET 4.0 and Visual Studio 2010
    -My posts after 12/2007 = .NET 3.5 and Visual Studio 2008
    -My posts after 04/2007 = .NET 3.0 and Visual Studio 2005
    -My posts before 04/2007 = .NET 1.1/2.0

    *I do not follow all threads, so if you have a secondary question, message me.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured