Smiley357 Posted September 11, 2008 Posted September 11, 2008 Is there a function that will read all directorys and files on the a drive and then output them to a txt file? Also, looking for a function that will do the same for the registry. I guess maybe doing a reg backup and renaming the .reg file to .txt. Any helpful hints/ideas would be appreciated.
will88 Posted September 11, 2008 Posted September 11, 2008 Is there a function that will read all directorys and files on the a drive and then output them to a txt file? Also, looking for a function that will do the same for the registry. I guess maybe doing a reg backup and renaming the .reg file to .txt. Any helpful hints/ideas would be appreciated. as for reading all the directorys under c: drive #include <Constants.au3> $foo = Run(@ComSpec & " /c dir", @HomeDrive, @SW_HIDE, $STDERR_CHILD + $STDOUT_CHILD) Sleep(1000) $line = StdoutRead($foo);reading command prompt FileWrite("C:\test.txt", $line);Output to C:\test.txt If that don't work then change the " /c dir" to "/c dir C:\" Password-Keeper
Smiley357 Posted September 11, 2008 Author Posted September 11, 2008 @Will88 Thanks for the code. Its a good starting point for what Im trying to do. I was looking at _FileListToArray when you posted your code. Basically what Im trying to do is write my own snapshot program. I want to take a snapshot of my hard drive and registry then install some freeware and see what has changed. I dont trust freeware that much but I like to use it. This way I can see if they try to hide things in the install. Im sure someone has done this already. But I figured I would give it a shot.
ksmith247 Posted September 11, 2008 Posted September 11, 2008 Check this post for the RecursiveFileSearch UDF by weaponx (#1 Array Based). Calling it like this... RecursiveFileSearch("C:\", ".") should do it.for the registry, try _RegSearch() by PsaltyDS. Support bacteria; it's the only culture most people have.LxP's Learning to Script with AutoIt 3 - Excellent starting placeVolly's Links Page - Links to cool and useful scriptsAutoIt Wrappers - Valuater's AutoIt Wrappers post. Lots of good stuff.Support AutoIt - Make a donation here; I did.[size="2"]#include <Guinness.pint>[/size]
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