Jump to content

Recommended Posts

Posted (edited)

Line 28

Send("12MouseDown("left")

Error: Unterminated string.

#region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=00000409)  ---


#region --- Internal functions Au3Recorder Start ---
Func _Au3RecordSetup()
Opt('WinWaitDelay',100)
Opt('WinDetectHiddenText',1)
Opt('MouseCoordMode',0)
Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '')
If $aResult[1] <> '00000409' Then
  MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(00000409->' & $aResult[1] & ')')
EndIf

EndFunc

Func _WinWaitActivate($title,$text,$timeout=0)
 WinWait($title,$text,$timeout)
 If Not WinActive($title,$text) Then WinActivate($title,$text)
 WinWaitActive($title,$text,$timeout)
EndFunc

_AU3RecordSetup()
#endregion --- Internal functions Au3Recorder End ---

_WinWaitActivate("Program Manager","")
MouseClick("left",650,44,2)
_WinWaitActivate("classname=WorkerW","")
_WinWaitActivate("Kronos Workforce Central(R) ‎- Microsoft Edge","")
Send("12MouseDown("left")

MouseClick("left",141,186,1)
MouseUp("left")
MouseClick("left",1184,21,1)
#endregion --- Au3Recorder generated code End ---

 

 

Edited by Melba23
Added code tags
  • Developers
Posted
  On 2/15/2017 at 7:40 PM, bweather04 said:

Send("12MouseDown("left")

Error: Unterminated string.

Expand  

 

  Quote
Is this a Win 10 thing?
Expand  

Why in the world would this be anything else than totally wrong syntax?
Check the helpfile for the proper syntax.

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted

K. But then the script still pauses::

 

#region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=00000409)  ---
#region --- Internal functions Au3Recorder Start ---
Func _Au3RecordSetup()
Opt('WinWaitDelay',100)
Opt('WinDetectHiddenText',1)
Opt('MouseCoordMode',0)
Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '')
If $aResult[1] <> '00000409' Then
  MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(00000409->' & $aResult[1] & ')')
EndIf
EndFunc
Func _WinWaitActivate($title,$text,$timeout=0)
 WinWait($title,$text,$timeout)
 If Not WinActive($title,$text) Then WinActivate($title,$text)
 WinWaitActive($title,$text,$timeout)
EndFunc
_AU3RecordSetup()
#endregion --- Internal functions Au3Recorder End ---
_WinWaitActivate("Program Manager","")
MouseClick("left",650,44,2)
_WinWaitActivate("classname=WorkerW","")
_WinWaitActivate("Kronos Workforce Central(R) ‎- Microsoft Edge","")
Send("12MouseDown("left")")
Send("4{BACKSPACE}{BACKSPACE}4161{TAB}{SHIFTDOWN}h{SHIFTUP}3ll0{SHIFTDOWN}1{SHIFTUP}976")
MouseClick("left",141,186,1)
MouseUp("left")
MouseClick("left",1184,21,1)
#endregion --- Au3Recorder generated code End ---
 
Doesn't run. It'll compile. But. No.
  • Developers
Posted
  On 2/15/2017 at 8:05 PM, bweather04 said:

K. But then the script still pauses::

Expand  

Not much info to assist you with is it? 
You could add the following statement which will tell you which line it is hanging when hovering the systray Icon:

Opt("TrayIconDebug", 1) ;0=no info, 1=debug line info

 

  On 2/15/2017 at 8:05 PM, bweather04 said:

Doesn't run. It'll compile. But. No.

Expand  

Again not must info in that sentence. No idea what you mean with "Doesn't run".
However you didn't really check the statement I pointed you to as far as syntax since it still doesn't make any sense but merely added a double quote to avoid an initial error.

Jos 

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted

probably hanging in

_WinWaitActivate("classname=WorkerW","")

"classname=WorkerW" should be "[CLASS:WorkerW]"

o.O

Send("12MouseDown("left")")
Send("4{BACKSPACE}{BACKSPACE}4161{TAB}{SHIFTDOWN}h{SHIFTUP}3ll0{SHIFTDOWN}1{SHIFTUP}976")

wow

  Reveal hidden contents

IUIAutomation - Topic with framework and examples

Au3Record.exe

  • 2 weeks later...
Posted (edited)

Yeah Yeah... I knew it was something within the class name. I've had this discussion before. - Can't remember what the proper syntax is.

AND YES. I knwo my pass is in there. I don't care. -- It's only for a timestamp at work.

#region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=00000409)  ---

Func _Au3RecordSetup()
Opt('WinWaitDelay',100)
Opt('WinDetectHiddenText',1)
Opt('MouseCoordMode',0)
Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '')
If $aResult[1] <> '00000409' Then
  MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(00000409->' & $aResult[1] & ')')
EndIf

EndFunc

Func _WinWaitActivate($title,$text,$timeout=0)
 WinWait($title,$text,$timeout)
 If Not WinActive($title,$text) Then WinActivate($title,$text)
 WinWaitActive($title,$text,$timeout)
EndFunc

_AU3RecordSetup()
#endregion --- Internal functions Au3Recorder End ---

_WinWaitActivate("Program Manager","");
MouseClick("left",650,44,2)
_WinWaitActivate("[CLASS:WorkerW]","")
_WinWaitActivate("Kronos Workforce Central(R) ‎- Microsoft Edge","")
Send("12MouseDown("left")")

MouseClick("left",141,186,1)
MouseUp("left")
MouseClick("left",1184,21,1)
#endregion --- Au3Recorder generated code End ---

 

Now it just doesn't error. Nor run? Error LIne #17

Edited by bweather04
Posted (edited)

#region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=00000409)  ---
Opt("TrayIconDebug", 1) ;0=no info, 1=debug line info
Func _Au3RecordSetup()
Opt('WinWaitDelay',100)
Opt('WinDetectHiddenText',1)
Opt('MouseCoordMode',0)
Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '')
If $aResult[1] <> '00000409' Then
  MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(00000409->' & $aResult[1] & ')')
EndIf

EndFunc

Func _WinWaitActivate($title,$text,$timeout=0)
 WinWait($title,$text,$timeout)
 If Not WinActive($title,$text) Then WinActivate($title,$text)
 WinWaitActive($title,$text,$timeout)
EndFunc

_AU3RecordSetup()
#endregion --- Internal functions Au3Recorder End ---

_WinWaitActivate("[class:WorkerW]","")
MouseClick("left",650,44,2)
_WinWaitActivate("Kronos Workforce Central(R) ‎- Microsoft Edge","")
Send("12MouseDown("left")")

MouseClick("left",141,186,1)
MouseUp("left")
MouseClick("left",1184,21,1)
#endregion --- Au3Recorder generated code End ---

 

Error Syntax Line 26::
Send("12MouseDown("left")")
Send("12MouseDown("^ERROR

Error: Unknown function name.

Edited by bweather04
Posted

#region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=00000409)  ---
Opt("TrayIconDebug", 1) ;0=no info, 1=debug line info
Func _Au3RecordSetup()
Opt('WinWaitDelay',100)
Opt('WinDetectHiddenText',1)
Opt('MouseCoordMode',0)
Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '')
If $aResult[1] <> '00000409' Then
  MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(00000409->' & $aResult[1] & ')')
EndIf

EndFunc

Func _WinWaitActivate($title,$text,$timeout=0)
 WinWait($title,$text,$timeout)
 If Not WinActive($title,$text) Then WinActivate($title,$text)
 WinWaitActive($title,$text,$timeout)
EndFunc

_AU3RecordSetup()
#endregion --- Internal functions Au3Recorder End ---

_WinWaitActivate("[class:WorkerW]","")
MouseClick("left",650,44,2)
_WinWaitActivate("Kronos Workforce Central(R) ‎- Microsoft Edge","")

MouseClick("left",141,186,1)
MouseUp("left")
MouseClick("left",1184,21,1)
#endregion --- Au3Recorder generated code End ---

 

Got it! THANK YOU FOR THE PROPER CLASS NAME!! @careca

Posted

Send("12MouseDown("left")") syntax was wrong.

  Reveal hidden contents

IUIAutomation - Topic with framework and examples

Au3Record.exe

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
  • Recently Browsing   0 members

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