Whenever I have any of these letters/numbers copied, I want them to go to certain lines to copy a name. In the end, I want the letters to all eventually go to Contractor, and all the numbers to go to Supplier. If the clipboard is 2, I want it to do something entirely different, but still end up going to Supplier.
Unfortunately, my script is only going to the first line and not going through all the whole script until it finds the copied text/number.
Code: Select all
\::
If Clipboard = A
Goto, A
If Clipboard = B
Goto, Contractor
If Clipboard = C
Goto, C
If Clipboard = CC
Goto, C
If Clipboard = CCC
Goto, C
If Clipboard = CCCC
Goto, C
If Clipboard = D
Goto, Contractor
If Clipboard = E
Goto, E
If Clipboard = EE
Goto, E
If Clipboard = F
Goto, F
If Clipboard = FF
Goto, F
If Clipboard = FFF
Goto, F
;Suppliers
If Clipboard = 1
Goto, Supplier
If Clipboard = 2
Goto, 2
If Clipboard = 22
Goto, 2
If Clipboard = 3
Goto, 3
If Clipboard = 33
Goto, 3
If Clipboard = 4
Goto, Supplier
If Clipboard = 44
Goto, Supplier
If Clipboard = 444
Goto, Supplier
If Clipboard = 5
Goto, Supplier
If Clipboard = 55
Goto, Supplier
If Clipboard = 6
Goto, Supplier
If Clipboard = 66
Goto, Supplier
If Clipboard = 7
Goto, Supplier
; Contractors 2
A:
Clipboard = Aaron
ClipWait
MsgBox A
Goto, Contractor
C:
Clipboard = Charlie
ClipWait
Goto, Contractor
D:
Clipboard = Dailey
ClipWait
Goto, Contractor
E:
Clipboard = Elmer
ClipWait
Goto, Contractor
F:
Clipboard = Frederick
ClipWait
Goto, Contractor
; Suppliers 2
2:
Clipboard = 20000000
ClipWait
Goto, Supplier
Exit
222:
Send, ^v
Exit
22:
Clipboard = 22
ClipWait
Goto, Adjuster
3:
Clipboard = James
ClipWait
Goto, Supplier
Contractor:
MsgBox Contractor
Sleep, 200
Send, ^v
Supplier:
MsgBox Supplier
Sleep, 200
Send, ^v
If Clipboard = 20000000
Goto, 22
Adjuster:
MsgBox Adjuster
Clipboard = 2222222222
Goto, 222