@Commander21
Kleiner Fehler von Dir, da Du eine "1" vergessen hast und dann noch etwas verkürtzt.
Spoiler anzeigen
[autoit]
#include <GUIConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 310, 65, 193, 125)
$Input1 = GUICtrlCreateInput("", 16, 32, 161, 21)
GUICtrlCreateLabel("Gib hier den Titel des Fensters ein, das sich aktivieren soll.", 16, 12, 279, 17)
$Button1 = GUICtrlCreateButton("Aktivieren", 180, 32, 113, 21, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
WinActivate (GUICtrlRead ($Input1), "")
EndSwitch
WEnd