The problem is that it works fine until I paste once and try to copy again : nothing is added to the clipboard.
I'm trying to figure it out , but couldn't find a reason for this..
here is the code :
#include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <array.au3> Global $clipBoard[50]=[""] Global $counter = 0 HotKeySet("^+q","addToClipboard") HotKeySet("^+-","emptyAll") HotKeySet("^+w","getAll") HotKeySet("^+1","get1") HotKeySet("^+2","get2") HotKeySet("^+3","get3") HotKeySet("^+4","get4") HotKeySet("^+5","get5") HotKeySet("^+6","get6") HotKeySet("^+7","get7") HotKeySet("^+8","get8") HotKeySet("^+9","get9") $hGUI = GuiCreate("Clipboard Controller", 100, 100,Default,Default,$WS_SIZEBOX) GUISetState() Func addToClipboard() Send ("^c") $copied = ClipGet() $clipBoard[Mod($counter,50)] = $copied $counter +=1 EndFunc Func getByIndex($i) $statement = $clipBoard[$i] ClipPut($statement) Send("^v") EndFunc Func getAll() $statement ="" For $i In $clipBoard If $i <> "" Then $statement &= $i & @CRLF EndIf Next ClipPut($statement) Send("^v") EndFunc Func emptyAll() For $i=0 To 49 $clipBoard[$i]="" Next ClipPut("") EndFunc Func get1() getByIndex(0) EndFunc Func get2() getByIndex(1) EndFunc Func get3() getByIndex(2) EndFunc Func get4() getByIndex(3) EndFunc Func get5() getByIndex(4) EndFunc Func get6() getByIndex(5) EndFunc Func get7() getByIndex(6) EndFunc Func get8() getByIndex(7) EndFunc Func get9() getByIndex(8) EndFunc While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd
any ideas/help ?





