Code: Select all
; Copy file to clipboard
SendInput "{Alt}{Right}{Enter}"
Sleep 1000
SendInput "C"
ClipWait
DeleteFile(ExportPth)
FileAppend A_Clipboard, ExportPth
Thank you
Code: Select all
; Copy file to clipboard
SendInput "{Alt}{Right}{Enter}"
Sleep 1000
SendInput "C"
ClipWait
DeleteFile(ExportPth)
FileAppend A_Clipboard, ExportPth
Code: Select all
#Requires AutoHotkey v2.0
acrobat := 'ahk_exe Acrobat.exe'
outFile := 'clips.txt'
#HotIf WinActive(acrobat)
F3 Up:: {
A_Clipboard := '', Send('^c')
If ClipWait(1) {
FileAppend A_Clipboard '`r`n', outFile
SoundBeep 1500
} Else MsgBox 'An error occurred while waiting for the clipboard.', 'Error', 'Icon!'
}
#HotIf
Comma (multi-statement). Commas may be used to write multiple sub-expressions on a single line. This is most commonly used to group together multiple assignments or function calls. For example: x:=1, y+=2, ++index, MyFunc(). Such statements are executed in order from left to right. In contrast to AutoHotkey v1, the comma operator usually performs worse than writing separate expressions. Performance continues to decrease as more and more expressions are combined into a single expression; for example, it can be 35 % slower to combine five or ten simple expressions into a single expression. The exception to this may be when combining function calls.
Source: Variables and Expressions - Definition & Usage | AutoHotkey v2