Jump to content

Loading Folder Names Into An Array?


Recommended Posts

Is it possible for autoit to load a directories folder names into an array. For example I have a folder called student, underneath that folder I have 500 folders with student names. I want to have autoit load all of the folders names (which are student names) into an array so I can then create more folders underneath each of there folders.

Is this even possible with autoit?

Thank you

Romeo

Link to comment
Share on other sites

Is it possible for autoit to load a directories folder names into an array. For example I have a folder called student, underneath that folder I have 500 folders with student names. I want to have autoit load all of the folders names (which are student names) into an array so I can then create more folders underneath each of there folders.

Is this even possible with autoit?

Thank you

Romeo

Straight from the Beta help file

#Include <File.au3>
#Include <Array.au3>
$FileList=_FileListToArray(@DesktopDir)
If (Not IsArray($FileList)) and (@Error=1) Then
    MsgBox (0,"","No Files\Folders Found.")
    Exit
EndIf
_ArrayDisplay($FileList,"$FileList")


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Link to comment
Share on other sites

Thank you, this is what I needed :)

you made my day.

Romeo

Straight from the Beta help file

#Include <File.au3>
#Include <Array.au3>
$FileList=_FileListToArray(@DesktopDir)
If (Not IsArray($FileList)) and (@Error=1) Then
    MsgBox (0,"","No Files\Folders Found.")
    Exit
EndIf
_ArrayDisplay($FileList,"$FileList")
Link to comment
Share on other sites

You are welcome. :):mellow::)


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

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