by Mark Biddlecom (2 Submissions)
Category: Complete Applications
Compatability: Visual Basic 5.0
Difficulty: Intermediate
Date Added: Wed 3rd February 2021
Rating:
(3 Votes)
This program will count the number of lines, characters, etc, of a specified list of files in a given folder (and optionally all of its subfolders). I plan to add more statistical data later, such as a list of the "top ten" files, by number of lines. The line counting method is simple: it counts all lines that contain any non-whitespace characters. It also counts the number of pure comment lines (those that start with a ' and contain no code) and displays that number. There are probably better counting algorithms out there but this project is somewhat tailored to the kind of coding I do. Among other things, this module also demonstrates how to use the Browse For Folder dialog (Windows API--thanks to Dev Ashish) and the FileSystemObject to recursively search for files. Please vote, as I'm just plain curious :P. --Mark
API DeclarationsTwo API functions for use in the Browse For Folder dialog. Check modBrowseForFolder.