Jump to content

Search the Community

Showing results for tags 'finding'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 3 results

  1. I have this very simple but possibly quite complicated idea for a program. It is kind of a rip of the "Find" function used in many programs and really is in a way a re-create. The problem is it take ages for the program to process the information and that is on a good PC (i5-6600, 16GB DDR4, SSD). The question, why? Why cant it work just like the find function, and how does the find function in many programs work so efficiently? Website for the words file as only allowed 4MB and it is 5MB : https://raw.githubusercontent.com/dwyl/english-words/master/words.txt Code: #include <File.au3> $Letters = InputBox("Letters","Input the letters you have.","","") If @error Then Exit $File_Words = @ScriptDir&"\words.txt" $Words = "Words:" $Amount = StringLen($Letters) $lines = _FileCountLines($File_Words) ProgressOn("Searching...","","") ProgressSet(0) For $i = 0 To $Amount $string = StringTrimRight($Letters,$i) For $j = 1 To $lines ProgressSet($lines/$j) If FileReadLine($File_Words,$j) = $string Then $Words = $Words&@CRLF&$string EndIf Next Next MsgBox(0,'',$Words)
  2. I'm pretty sure that I have this file except it doesn't have an extension. This code returns an error: $Dummies = @ScriptDir & "\Dummies" $sFind = "109.99.99.99" $sReplace = "No Longer Use"     if FileExists($Dummies) Then         _ReplaceStringInFile($Dummies,$sFind ,$sReplace)     Else         MsgBox(0, "Error", "Make sure Dummies file exist before you proceed to compile this project.")         Return     EndIf If it has an extension then it's ok, but if it doesn't have an extension then it returns an error msgbox that I created. Any help is appreciated. EDIT: I figured... I didn't show the extension. So it was Dummies.txt all along.
  3. Hello everyone, I'm trying to make a script that tells me the location of a specified file, in this case lets say I'm searching for a file named "hamster.jpg" So I want to search my entire computer for this file, so I'm using Melba's UDF (RecFileListToArray). My problem is that I seem to only be able to find hamster.jpg if I do a search for ".jpg" (as seen in my code below). This also shows me all the other .jpg's I have on my computer, which is fine. If I do a search for "hamster", I won't see any results. So it seems like I can only search file extensions and not the file name itself. Can anyone guide me on how to make my code search for file names as well? Thank you, Brian #include <Array.au3> #include <RecFileListToArray.au3> Example() Func Example() Local $aArray, $aDrives = DriveGetDrive("FIXED") ;Makes sure all the drives are searched If @error = 0 Then For $i = 1 To $aDrives[0] $aArray = _RecFileListToArray($aDrives[$i] & "", "*.jpg", 1, 1, 0, 2) If @error Then ContinueLoop EndIf For $j = 1 To $aArray[0] ConsoleWrite($aArray[$j] & @CRLF) Next Next EndIf EndFunc ;==>Example So in the above code, if I change the "*.jpg" to "*hamster", I won't be able to find my hamster picture D:. EDIT: I figured it out. Wow.. The only different thing I had to do in order to find the file name was write "hamster" on the left side of the * instead of the right side of the *
×
×
  • Create New...