Jump to content

Unable to log


Recommended Posts

Good evening. I wanted to log my progress and made a little checker. Unfort. I get unable to open file when executed. Already checked the permissions and file . Thanks ..

Func StartLog()

if $file = 0 then
ToolTip('Opening log file',0,0)
sleep($pingwait + Random(-$randamount, $randamount))
$file = FileOpen ( $log, 0)
If $file = -1 Then
MsgBox(0, "Error", "Unable to open log file.")
EndScript()
EndIf
Endif

;$line = FileReadLine($file, -1)

if $logOn = 0 then
while 1
ToolTip('Starting Log file',0,0)
Send("/")
sleep($pingwait/2 + Random(-$randamount, $randamount))
Send("log")
sleep($pingwait/2 + Random(-$randamount, $randamount))
Send("{ENTER}")
sleep($pingwait/2 + Random(-$randamount, $randamount))
$line = FileReadLine($file, -1)
if StringRegExp($line, ['logging enabled') = 1 Then
$logOn = 1
ExitLoop
endif
Wend
EndIf
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...