Jump to content

Gettin file count from a directory excluding subdirectories


Recommended Posts

Hello

This is the only function i could find in the help file to get a file count of a directory. But i dont want the subdirs included in file count. How can i exclude the subdirs from count ?

$sinsi = DirGetSize("c:\Documents and Settings\aozben\Desktop\Cap Rep\",1)
_ArrayDisplay($sinsi)
Link to comment
Share on other sites

Hi alfa,

you can use _FileListToArray() to count files. The resulting array has the number of files in the [0] array element.

Regards,Hannes[spoiler]If you can't convince them, confuse them![/spoiler]
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...