Jump to content

File Searching Algorithm


Recommended Posts

i've thought about making one, but it is alot of work(well, the only way i know how)

firs u would need to get an array of all the folder in @HomeDrive

then make an array of all the files in @HomeDrive

and then keep going deeper.... IE: @HomeDrive & $array[5], @HomeDrive & $array[3] & $array[4] and just put it in a for-loop.

lol, it probably does'nt make sense to you, but it is hard to explain.

good luck.

Link to post
Share on other sites

AutoIt Beta required (current: 3.1.1.108)

$drive = DriveGetDrive('FIXED')
If Not @error Then
    For $i = 1 To $drive[0]
        MsgBox(0, '', _RunStdout(@ComSpec & ' /c dir /s/b "' & $drive[$i] & '\*.scm"'))
    Next
EndIf

Func _RunStdOut($_command)
    Local $data_out, $stdout = Run($_command, '', @SW_HIDE, 2)
    While 1
        $data_out &= StdOutRead($stdout)
        If @error Then ExitLoop
    WEnd
    If Not $data_out Then
        Return SetError(1, 0, '')
    Else
        Return $data_out
    EndIf
EndFunc

Edit: UDF had a issue. Added just a basic version to do the task.

Edited by MHz
Link to post
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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...