ich hab mal ein kleine tool geschrieben, und komme an der stelle nicht weiter:
es will einfach nicht "left" mit den "" schreiben....
wie mach ich das?
und 2. wie kann ich es machen, das wenn es die sachen in die editbox schreibt, bei jeden weiteren "TAB" drücken eine zeile drunter das nächste kommt?
bisjetz komplette source:
MfG
PHP Code:
GUICtrlSetData($edit1, "MouseClick("&"left"&" , "& $pos[0] &", "& $pos[1] &", 1)")
wie mach ich das?
und 2. wie kann ich es machen, das wenn es die sachen in die editbox schreibt, bei jeden weiteren "TAB" drücken eine zeile drunter das nächste kommt?
bisjetz komplette source:
PHP Code:
#include <Misc.au3>
#include <ComboConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ###
$Form1_1 = GUICreate("Form1", 355, 154, 211, 154)
$Label1 = GUICtrlCreateLabel("X-Achse", 4, 8, 44, 17)
$Label2 = GUICtrlCreateLabel("Y-Achse", 4, 36, 44, 17)
$Label3 = GUICtrlCreateLabel("Farbe", 4, 72, 31, 17)
$input1 = GUICtrlCreateInput("", 56, 4, 101, 21)
$input2 = GUICtrlCreateInput("", 56, 32, 101, 21)
$input3 = GUICtrlCreateInput("", 56, 68, 101, 21)
$edit1 = GUICtrlCreateEdit("", 172, 24, 177, 85)
$Label4 = GUICtrlCreateLabel("Bitte drücken Sie die TAB-Taste um die Position und Farbe zu speichern!", 4, 120, 347, 17)
$Option = GUICtrlCreateCombo("Option", 172, 0, 173, 25)
GUICtrlSetData(-1, "MouseClick()")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
start()
WEnd
Func start()
$pos = MouseGetPos()
$farbe = PixelGetColor($pos[0], $pos[1])
GUICtrlSetData($input1, $pos[0])
GUICtrlSetData($input2, $pos[1])
GUICtrlSetData($input3, "0x" & Hex($farbe, 6))
$dll = DllOpen("user32.dll")
If _IsPressed("09", $dll) Then
If GUICtrlRead($Option) = "option" Then
GUICtrlSetData($edit1, $pos[0] & @CRLF & $pos[1] & @CRLF & @CRLF & "0x" & Hex($farbe, 6))
ElseIf GUICtrlRead($Option) = "MouseClick()" Then
GUICtrlSetData($edit1, "MouseClick("&"left"&" , "& $pos[0] &", "& $pos[1] &", 1)")
EndIf
EndIf
DllClose($dll)
EndFunc