Autoit GUICreateEdit

04/10/2008 20:32 starkalex#1
Hey

Frage:
Ich möchte gerne ein Bestimmtes Wert den ich in "GUICtrlCreateEdit"
Eingebe an die tastatur senden z.B "xxx"

Und wenn ich "GUICtrlCreateButton" $Button1 drücke den soll der Wert
"xxx" gesendet

Code:

Code:
#include <GUIConstants.au3>

GUICreate("My GUI")
$Button1 = GUICtrlCreateButton( "wert", 225, 75 ,50 ,25,  $BS_ICON)
$Button2 = GUICtrlCreateEdit( "", 75, 78 ,60,20,  $BS_ICON)
GUISetState (@SW_SHOW)


While 1
	$msg = GUIGetMsg()
	
	If $msg = $GUI_EVENT_CLOSE Then ExitLoop
    If $msg= $Button1 then ....

Wend
04/13/2008 11:23 Hikkikomori#2
#include <GUIConstants.au3>

GUICreate("My GUI")
$Button1 = GUICtrlCreateButton("wert", 225, 75, 50, 25, $BS_ICON)
$Button2 = GUICtrlCreateEdit("", 75, 78, 60, 20, $BS_ICON)
GUISetState(@SW_SHOW)


While 1
$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then ExitLoop
If $msg = $Button1 Then
MsgBox(0, "", GUICtrlRead($Button2))
EndIf
WEnd



[code] tags funzen irgendwie nicht, der löscht dann automatisch nen paar wörter..