Hey,
ich habe folgendes Szenario:
[autoit]#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 251, 120, -1, -1)
$Button1 = GUICtrlCreateButton("Make GUI", 48, 32, 155, 49, $WS_GROUP)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
$button3 = -1
While 1
$nMsg = GUIGetMsg(1)
Switch $nMsg[0]
Case $GUI_EVENT_CLOSE
Exit
case $Button1
$Form2 = GUICreate("andere GUI", 246, 166, 192, 124)
$Button2 = GUICtrlCreateButton("Button", 32, 80, 75, 25, $WS_GROUP)
$Label2 = GUICtrlCreateLabel("LABEL", 64, 16, 37, 17)
$Checkbox2 = GUICtrlCreateCheckbox("Control", 120, 40, 97, 17)
$Button3 = GUICtrlCreateButton("EXIT", 152, 128, 75, 25, $WS_GROUP)
GUISetState(@SW_SHOW)
Case $Button3
GUIDelete ($nMsg[1])
EndSwitch
WEnd
Ich möchte, dass jedes Fenster (andere GUI) einzigartig bleibt und trotzdem schließt,
wenn ich auf EXIT klicke.
Das Problem ist, dass die GUI neu erstellt wird und somit $Button3 einen neuen Wert bekommt.
Wie könnte ich das Problem lösen, dass trotzdem immer das Fenster zugeht, wenn ich auch auf EXIT klicke?!
Vielen Dank schonmal im Voraus
Gruß Snify