Xand3r Posted February 1, 2007 Share Posted February 1, 2007 CODE#include <File.au3> $dir="C:" Global $path=$dir FileChangeDir($dir) scan() Func scan() $a=_FileListToArray (@WorkingDir ,"*" , 2 ) If @error=4 Then;@error=4 dak nu gaseste foldere $b=_FileListToArray(@WorkingDir , "*" , 1) For $j=1 to $b[0] FileWrite(@DesktopDir&"\lista.txt", $path&"\"&$b[$j]&@CRLF) Next SetError(0) ElseIf @error=0 Then For $i=1 to $a[0] $path=$path&$a[$i] FileChangeDir($path) scan() Next EndIf EndFunc ok this is supposed to make a list of all the files in the c: dir but nothing happends except for the error recursion level overflowed???? why is that happening it's only supposed to recurse itself a couple of times at moast 20 i think Only two things are infinite, the universe and human stupidity, and i'm not sure about the former -Alber EinsteinPractice makes perfect! but nobody's perfect so why practice at all?http://forum.ambrozie.ro Link to comment Share on other sites More sharing options...
Uten Posted February 1, 2007 Share Posted February 1, 2007 (edited) Add some trace lines in there.. ConsoleWrite($path & @LF) Or search for "Func dbg" and use that. EDIT: Both requires a editor capturing ConsoleWrite. SciTE4Autoit3 (or scite in the scite subfolder of a resent installation) does. Edited February 1, 2007 by Uten Please keep your sig. small! Use the help file. Search the forum. Then ask unresolved questions :) Script plugin demo, Simple Trace udf, TrayMenuEx udf, IOChatter demo, freebasic multithreaded dll sample, PostMessage, Aspell, Code profiling Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted February 1, 2007 Moderators Share Posted February 1, 2007 _FileListToArrayEx Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now