Tigerweld Posted February 16, 2008 Share Posted February 16, 2008 I've searched this forum and I'm sure I'm missing it, but I'm looking for some code to jump start me in creating something that will open a log file (newest modified date) and scan for the word 'failed' or 'success' and be able to send an email depending on what it finds. I just need some examples to point me in the right direction. Thanks for any insight, code, or ideas! Link to comment Share on other sites More sharing options...
Tomb Posted February 16, 2008 Share Posted February 16, 2008 I've searched this forum and I'm sure I'm missing it, but I'm looking for some code to jump start me in creating something that will open a log file (newest modified date) and scan for the word 'failed' or 'success' and be able to send an email depending on what it finds. I just need some examples to point me in the right direction.Thanks for any insight, code, or ideas!eh, what practical use does this have? Link to comment Share on other sites More sharing options...
rmarino Posted February 16, 2008 Share Posted February 16, 2008 You could look at these: FileOpen FileReadLine StringInStr _INetSmtpMail (I haven't used this) Link to comment Share on other sites More sharing options...
goldenix Posted February 16, 2008 Share Posted February 16, 2008 unfortunately i dont have my other HDD so i cant post my hyper ultimate search script, so bear with this....help file sample ^^ $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 While 1 $line = FileReadLine($file) If @error = -1 Then ExitLoop if StringInStr($line,'failed') Then MsgBox(4096, "Test", "found failed") Wend FileClose($file) My Projects:[list][*]Guide - ytube step by step tut for reading memory with autoitscript + samples[*]WinHide - tool to show hide windows, Skinned With GDI+[*]Virtualdub batch job list maker - Batch Process all files with same settings[*]Exp calc - Exp calculator for online games[*]Automated Microsoft SQL Server 2000 installer[*]Image sorter helper for IrfanView - 1 click opens img & move ur mouse to close opened img[/list] Link to comment Share on other sites More sharing options...
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