![Wink ;)](./images/smilies/icon_e_wink.gif)
If I run this script while the "Export" window is open, it puts the cursor where I expect
Code: Select all
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
if WinExist("ahk_exe Adobe Premiere Pro.exe")
WinActivate, ahk_exe Adobe Premiere Pro.exe
else
Exit
SendInput +4 ; Adobe Premiere short cut to the program window, otherwise, export may not open
Sleep, 500
ControlFocus ,Edit19
ControlGetPos, X, Y,,,Edit19
;MsgBox ,,%X% %Y%
MouseMove %X%, %Y%, 20
MouseMove, 0, 55, 20, R
MouseClick
Code: Select all
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
if WinExist("ahk_exe Adobe Premiere Pro.exe")
WinActivate, ahk_exe Adobe Premiere Pro.exe
else
Exit
SendInput +4 ; Adobe Premiere short cut to the program window, otherwise, export may not open
Sleep, 500
; should work doesn't 'SendInput ^M ; Ctrl+M to open Export Media window'
SendInput !F
Sleep, 500
Send e
Sleep, 500
Send e
Send {Right}
Sleep, 500
Send {Enter}
;SendInput +4 ; Adobe Premiere short cut to the program window, otherwise, export may not open
Sleep, 1000
Send, {Tab}
Sleep, 500
Send, {Tab}
Sleep, 500
Send, {Tab}
Sleep, 500
Send, {Tab}
Sleep, 500
Send, {Tab}
Sleep, 500
Send, {Tab}
Sleep, 500
; we should be there anyway now
ControlFocus ,Edit19
Sleep, 500
ControlGetPos, X, Y,,,Edit19 ; NOT WORKING IN THIS SCRIPT? WHY?
;MsgBox ,,%X% %Y%
MouseMove %X%, %Y%, 20
MouseMove, 0, 55, 20, R
MouseClick