Advertisement
Guest User

Untitled

a guest
Nov 7th, 2023
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. :X:string::UseTemplate("string")
  2.  
  3. UseTemplate(Filename) {
  4. bak := ClipboardAll
  5. Clipboard := ""
  6. FileRead CLipboard, % "D:\AHKTemplates\" Filename ".txt"
  7. ClipWait 1
  8. if (ErrorLevel) {
  9. MsgBox 0x10, Error, Couldn't set template text.
  10. } else {
  11. Send ^v
  12. Sleep 100
  13. }
  14. Clipboard := bak
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement