Hallo,
hab in meinem script eine etwas verzweigte while-schleifenstruktur
soweit hab ich das prinzip ja schon verstanden und die schleife funktioniert soweit ganz gut
einziges problem ist das man beim verlassen des 2 fensters (der while-schleife für das $texthttpfenster2)
wieder zurück in die andere whileschleife kommt
ich möchte aber das wenn der $OKurl button und anschließend der $OKurl2 button gedrückt wurde, man aus der while 1- und while 2-schleife komplett herauskommt.
wie setzt man das um?
Spoiler anzeigen
Case ...
Case $http
$texthttpfenster = GUICreate("Texteingabe für URL:", 350, 120)
GUICtrlCreateLabel("Geben sie bitte die URL des Links ein.", 30, 20)
$texturl = GUICtrlCreateInput("", 30, 45, 290, 23)
GUICtrlSetFont(-1, 11, 400, 0, "MS Sans Serif")
$OKurl = GUICtrlCreateButton("OK", 90, 80, 75, 25)
$AbbrechenURL = GUICtrlCreateButton("Abbrechen", 175, 80, 75, 25)
GUISetState(@SW_SHOW, $texthttpfenster)
While 1
$texthttpfenster = GUIGetMsg()
Switch $texthttpfenster
Case $GUI_EVENT_CLOSE
GUISetState(@SW_HIDE)
ExitLoop
Case $OKurl
$texthttpfenster2 = GUICreate("Texteingabe für Name:", 350, 120)
GUICtrlCreateLabel("Geben sie bitte den Namen des Links ein.", 30, 20)
$texturl2 = GUICtrlCreateInput("", 30, 45, 290, 23)
GUICtrlSetFont(-1, 11, 400, 0, "MS Sans Serif")
$OKurl2 = GUICtrlCreateButton("OK", 90, 80, 75, 25)
$AbbrechenURL2 = GUICtrlCreateButton("Abbrechen", 175, 80, 75, 25)
GUISetState(@SW_SHOW, $texthttpfenster2)
While 2
$texthttpfenster2 = GUIGetMsg()
Switch $texthttpfenster2
Case $GUI_EVENT_CLOSE
GUISetState(@SW_HIDE)
ExitLoop
Case $OKurl2
GUICtrlSetData($text, GUICtrlread($text) & '' & GUICtrlread($texturl2) & '')
GUISetState(@SW_HIDE)
GUISetState(@SW_HIDE)
ExitLoop
Case $AbbrechenURL2
GUISetState(@SW_HIDE)
ExitLoop
EndSwitch
WEnd
Case $AbbrechenURL
GUISetState(@SW_HIDE)
ExitLoop
EndSwitch
WEnd
Case ...