Jump to content

Counting array and searching for .exe


Dryden
 Share

Recommended Posts

Hi! I know my questions are probabily as simple as they can get, but I'l ask them anyway cosn I can't find an answer with any of the _Array commands, so here it goes:

How do I count the number of variables inside of an array?

Also, how do I find all exe's inside sub folders?

for example:

$Ficheiros=_FileListToArray("z:\","*.exe",0)

so my problem with this is that I dunno how many files are in the array, also I can't get the contents of any sub-folders in drive z:

"Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life." - Terry Pratchett.

Link to comment
Share on other sites

From Autoit help on _FileListToArray

The array returned is one-dimensional and is made up as follows:

$array[0] = Number of Files\Folders returned <<<<<<<<

$array[1] = 1st File\Folder

$array[2] = 2nd File\Folder

$array[3] = 3rd File\Folder

$array[n] = nth File\Folder

Link to comment
Share on other sites

From Autoit help on _FileListToArray

duh! i'm so dumb :S I didn't even notice that :S

And what about scanning sub-folders, any Ideas?

"Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life." - Terry Pratchett.

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...