dion Posted July 22, 2011 Posted July 22, 2011 (edited) Dear folks.. I have the following script that I had written to capture TeamViewer QuickSupport after it had launch. It was working fine for past 1year but recently the screen capture was too "fast". It could not capture the ID portion. I had tried to use ControlGetText to check if values was in that ID box but was not successful. Any ideas and guidience on how I could accomplish a screen shot and ensuring there is a ID before screen capture. Thank you in advance. #include <ScreenCapture.au3> #Include <Date.au3> $TVQSPATH = @ScriptDir & "\TeamViewerQS.exe" $Date = (_DateTimeFormat( _NowCalc(),2)) $Date2 = @MDAY & @MON & @YEAR $Time = _NowTime() $FName = @ScriptDir & "\TVID" & $Date2 & ".jpg" ;Run TeamViewer Run($TVQSPATH) WinWaitActive ("TeamViewer" , "Ready to connect (secure connection)") $TVS = WinGetHandle("[active]") ;Capture window _ScreenCapture_CaptureWnd ($FName, $TVS) WinSetState ( $TVS , "" , @SW_MINIMIZE) Edited July 22, 2011 by dion
tlman12 Posted July 22, 2011 Posted July 22, 2011 Dear folks.. I have the following script that I had written to capture TeamViewer QuickSupport after it had launch. It was working fine for past 1year but recently the screen capture was too "fast". It could not capture the ID portion. I had tried to use ControlGetText to check if values was in that ID box but was not successful. Any ideas and guidience on how I could accomplish a screen shot and ensuring there is a ID before screen capture. Thank you in advance. #include <ScreenCapture.au3> #Include <Date.au3> $TVQSPATH = @ScriptDir & "\TeamViewerQS.exe" $Date = (_DateTimeFormat( _NowCalc(),2)) $Date2 = @MDAY & @MON & @YEAR $Time = _NowTime() $FName = @ScriptDir & "\TVID" & $Date2 & ".jpg" ;Run TeamViewer Run($TVQSPATH) WinWaitActive ("TeamViewer" , "Ready to connect (secure connection)") $TVS = WinGetHandle("[active]") ;Capture window _ScreenCapture_CaptureWnd ($FName, $TVS) WinSetState ( $TVS , "" , @SW_MINIMIZE) WinWaitActive("TeamViewer","Connecting to Keep") WinWaitActive("TeamViewer","Ready to connect") $test = ControlGetText("TeamViewer","Ready to connect","[CLASS:Edit; INSTANCE:1]") MsgBox(0,"",$test)
dion Posted July 23, 2011 Author Posted July 23, 2011 WinWaitActive("TeamViewer","Connecting to Keep") WinWaitActive("TeamViewer","Ready to connect") $test = ControlGetText("TeamViewer","Ready to connect","[CLASS:Edit; INSTANCE:1]") MsgBox(0,"",$test) Hi tlman12, it workds If have include if $var <> 0 then it do the screen capture. Thank you for the help.
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