Jump to content

butane

Members
  • Posts

    3
  • Joined

  • Last visited

butane's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Bingo! This solution works magically...now I just have to think about it for a few hours to understand it. Thanks you both, very good answers! Cheers!
  2. Roger that, I have made an easier to read example for testing purposes. I also uploaded a text document with some test names. Thanks for the reply!! #include <WinAPIFiles.au3> #include <Array.au3> #include <File.au3> #include <FileConstants.au3> #RequireAdmin $ReadUsrInfoSearch = "John" $FileOpen = FileOpen("C:\UserList.txt") $FileRead = FileRead($FileOpen) FileClose($FileOpen) $aResult = StringSplit(StringStripWS($FileRead,4)," ") _ArrayDisplay($aResult) $blab = _ArrayFindAll($aResult, "Ra", Default, Default, Default, 1, Default, False) _ArrayDisplay($blab) UserList.txt
  3. Hello All, I have been a lurker for a good bit but have finally hit a stumbling block that I can't seem to overcome (even though it is undoubtedly super simple). I need some assistance if possible. Basically I have a giant list of names - 70k+ in a .txt document (but in the future probably coming from a direct STDOUT stream) I first StringSplit them and strip white space. Then I have a giant array that looks good on display. I do an _ArrayFindAll and it returns to me the element ID's instead of names... I need the names and can't figure out how to properly extract them. Ultimately the names will go in a list box that when selected will fill a field. I know I am just being stupid. Any help you could offer would be greatly appreciated. Here is a snippet of what I've got goin on. Case $ButtonSearch $ReadUsrInfoSearch = GUICtrlRead($F_GET_USRNME) $FileOpen = FileOpen("C:\name.txt") $FileRead = FileRead($FileOpen) FileClose($FileOpen) $aResult = StringSplit(StringStripWS($FileRead,4)," ") $blab = _ArrayFindAll($aResult, $ReadUsrInfoSearch, Default, Default, Default, 1, Default, False) _ArrayDisplay($blab) If @error Then MsgBox($MB_SYSTEMMODAL, "Not Found", ':' & $ReadUsrInfoSearch) Thanks in advance!!!
×
×
  • Create New...