Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

Array in arrays - _FileListToArray

$
0
0
Hi all,
I am really noobish in autoIT but i am a good programmer. :geek:
the final product i want to do is a treeview of all the batches files and the folders in one folder (which content sub-folders with more batch)
Like a dir command with checkboxes in the batch
I started to do and array of the folders using _FileListToArray

[ autoit ]      
$hTreeView = GUICtrlCreateTreeView(2, 2, 396, 268) $FolderList=_FileListToArray(@ScriptDir,"*",2) $NumberOfFolders = $FolderList[0]-1 local $FileListFolder[$NumberOfFolders][10],$TreeView[$NumberOfFolders] For $x=1 To $NumberOfFolder MsgBox(0,"test",@ScriptDir & "\"& $FolderList[$x]) $FileListFolder[$x]=_FileListToArray(@ScriptDir & "\"& $FolderList[$x],"*",1) Next _GUICtrlTreeView_BeginUpdate($hTreeView) For $x = 0 To $NumberOfFolders $TreeView[$x]=GUICtrlCreateTreeViewItem($FolderList[$x], $hTreeView) For $y = 0 To GUICtrlCreateTreeViewItem($FileListFolder[$x][$y], $TreeView[$x]) Next Next _GUICtrlTreeView_Expand($hTreeView) _GUICtrlTreeView_EndUpdate($hTreeView)

And I got error in this line:
$FileListFolder[$x]=_FileListToArray(@ScriptDir & "\"& $FolderList[$x],"*",1)

Quote

Array variable has incorrect number of subscripts or subscript dimension range exceeded.

I dont know what i did wrong..
Could anyone help me?
Thanks :thumbsup:
-elad

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>