Jump to content

brodie28

Active Members
  • Posts

    183
  • Joined

  • Last visited

brodie28's Achievements

Prodigy

Prodigy (4/7)

0

Reputation

  1. I have been using IE.au3 for a long time now and it has been a great UDF... I have a question for people who have used IE.au3 alot as well... Sometimes when I am running a script (Could be running for hours and hours) which is controlling an IE window, IE will fail to load the page correctly. This has nothing to do with IE.au3 just sometimes the page will not fully load or it will not load the way it should. A simple reloading of the page would fix this but at the moment my scripts crash when it happens, normally because it tries to find a form or a form element which is not there. what is the best way to determine if the page has not loaded correctly? Iv tried a few different if statements using @error but can't seem to come up with something which is reliable enough to use.
  2. I want to use _INetSmtpMail to send emails to my gmail account. The problem I have is finding a good, free reliable mail server I can use. Can anyone help me?
  3. But for that to work, wouldn't the PC it is running on need to have Hamachi installed? I was playing around with the SMTP sendmail function today and in testing could not get it to send an email successfully with several SMPT servers (Gmail, yahoo etc.) Still after ideas.
  4. I was wondering what autoits most reliable way of sending information accross the internet is? Just some basic text needs to be sent... I was wondering how reliable The InetSMTPmail functions are... What worries me is finding a reliable mail server. The only other things I could think of is TCP/IP stuff which I am not really familiar with or just loading a webpage and submitting it....
  5. That didn't work. That only returns strings that are one character long. I want it to return all strings that contain nothing but a-z, 0-9 and _ -
  6. thanks. I never could get my heard around regexp... What would I do to include "-" and "_" in that?
  7. All sorts of random symbols get included as being alpha numeric. For instance ß and all sorts of other ones. Is there a way to just evaluate a string to see if it is a-z 0-9?
  8. Thanks, that last one worked perfectly, and MUCH faster than anything else I tried. I assume it worked anyway, notepad really struggles to open text files of this huge size. EDIT: something didn't work. It is much much smaller than it should be and alot of things seem to have been deleted when they shouldnt have been. Ill try to see why. Edit2: Im an idiot. The script I used to split one massive text file into 100 smaller ones had an error (I accidentally left something inside a loop when it should have been out) so all the text files turned out the same. Thats now been corrected and the last script is working perfectly.
  9. I ran into an error where Arraydelete was rediming the array to a smaller size, so after a while the array would be out of range with the for loop. So I did this. strangely it is going much much faster this way, seemingly for no reason. #include <Array.au3> #Include <File.au3> for $i = 1 to 100 $fname = "passlist" & $i & ".txt" dim $aArray[9999999] ConsoleWrite($fname & @CRLF) _FileReadToArray($fname, $aArray) $size = $aArray[0] redim $aArray[$size] for $x = 1 to $size ConsoleWrite("file " & $i & " " & $x & " from " & $size & @CRLF) if StringIsAlNum ($aArray[$x]) = 0 Then _ArrayDelete($aArray, $x) $size = $size - 1 EndIf Next _FileWriteFromArray($fname, $aArray) Next
  10. I have to keep redimming the array because Im not sure how to define an array of unknown size in autoit (Im not sure you can). So I have to redim it for every text file. Anyway, the script gets stuck in the nested for loop, which is where the time is being taken. SmokeN, if I get rid of consolewrite, do you think it will make a difference? Its probably going to take hours anyway, and I would kind of like to know where its up to. Any way to do that without consolewrite?
  11. #include <Array.au3> #Include <File.au3> for $i = 1 to 100 $fname = "passlist" & $i & ".txt" dim $aArray[9999999] ConsoleWrite($fname & @CRLF) _FileReadToArray($fname, $aArray) $size = $aArray[0] redim $aArray[$size] for $x = 1 to $aArray[0] ConsoleWrite("file " & $i & " " & $x & " from " & $aArray[0] & @CRLF) if StringIsAlNum ($aArray[$x]) = 0 Then _ArrayDelete($aArray, $x) EndIf Next _FileWriteFromArray($fname, $aArray) Next Basically I have 100 text files, all with about 95000 lines of text... I want to go through all of these text files and delete every line in the text file that is not alpha numeric only. This works... But god is it slow. Any ideas on why it is only writing to the console about once a second? EDIT: It is actually about twice a second... Maybe thats just as fast as it can go?
  12. $file = FileOpen("test.txt", 0) ; Check if file opened for reading OK If $file = -1 Then MsgBox(0, "Error", "Unable to open file.") Exit EndIf ; Read in lines of text until the EOF is reached Global $total = "" While 1 $line = FileReadLine($file) If @error = -1 Then ExitLoop if not StringInStr($total,$line,0) >= 1 Then $total = $total & $line & @CRLF EndIf Wend ;MsgBox(1,"Total",$total) Fileclose($file) FileOpen ( "test.txt", 2 ) FileWrite($file, $total) FileClose($file) That ended up doing the job... I could have thrown this together myself I was just feeling lazy I guess
  13. I am looking for a way to remove all identical lines from a text file. All I can find on the web are lame programs that need you to register for them to work... I couldnt find any in the examples page and really dont feel like making one myself right now. Does anyone know of one? In case you dont understand what I mean... Say a text file was dog dog cat horse dog horse cow Then what would be returned would be dog cat horse cow Same order, no duplicates.
  14. Someone is decompiling my scripts to get admin passwords and use features of the script I don't want everyone to be able to access. Is there anything I can do to stop decompilation or at least make the passwords more secure somehow? Even if I could make the passsword more secure... If someone can decompile the script they could just edit out the need for a password themselves. Anything I can do?
×
×
  • Create New...