Since it looks like you're wanting to get the file count of a directory on a Windows system, you might want to check out Win32::DirSize. Basically you call Win32::DirSize's dir_size function and pass in the path of the directory and FileCount is one of the keys of the returned hash.
Of course, if you're trying learn how to do this on your own or need something that will work on non-Windows platforms, then Win32::DirSize may not be the best choice to go with.
In reply to Re: Count files in directories
by dasgar
in thread Count files in directories
by begood321
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |