Code:
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
Opt("GUIOnEventMode", 1)
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Renomeador", 223, 131, 200, 200)
GUISetOnEvent($GUI_EVENT_CLOSE, "exit_")
$input1 = GUICtrlCreateInput("Element Client", 24, 40, 113, 21)
$Input2 = GUICtrlCreateInput("Element Client2", 24, 88, 113, 21)
$Button1 = GUICtrlCreateButton("Renomear", 144, 40, 67, 65)
GUICtrlSetOnEvent($Button1, "rename")
$Button2 = GUICtrlCreateButton("1", 24, 16, 19, 17)
GUICtrlSetOnEvent($Button2, "rename_1")
$Button3 = GUICtrlCreateButton("2", 48, 16, 19, 17)
GUICtrlSetOnEvent($Button3, "rename_2")
$Button4 = GUICtrlCreateButton("3", 72, 16, 19, 17)
GUICtrlSetOnEvent($Button4, "rename_3")
$Button5 = GUICtrlCreateButton("4", 96, 16, 19, 17)
GUICtrlSetOnEvent($Button5, "rename_4")
$Button6 = GUICtrlCreateButton("5", 120, 16, 19, 17)
GUICtrlSetOnEvent($Button6, "rename_5")
$Button7 = GUICtrlCreateButton("1", 24, 64, 19, 17)
GUICtrlSetOnEvent($Button7, "rename_6")
$Button8 = GUICtrlCreateButton("2", 48, 64, 19, 17)
GUICtrlSetOnEvent($Button8, "rename_7")
$Button9 = GUICtrlCreateButton("3", 72, 64, 19, 17)
GUICtrlSetOnEvent($Button9, "rename_8")
$Button10 = GUICtrlCreateButton("4", 96, 64, 19, 17)
GUICtrlSetOnEvent($Button10, "rename_9")
$Button11 = GUICtrlCreateButton("5", 120, 64, 19, 17)
GUICtrlSetOnEvent($Button11, "rename_10")
$Group1 = GUICtrlCreateGroup("Renomear Janelas", 8, 0, 209, 121, BitOR($GUI_SS_DEFAULT_GROUP,$BS_CENTER))
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
sleep(100)
WEnd
Func rename()
$Nome_Antigo = GUICtrlRead($Input1)
$Novo_Nome = GuiCtrlRead($Input2)
WinSetTitle($Nome_Antigo,"",$Novo_Nome)
EndFunc
Func rename_1()
GUICtrlSetData ($Input1,"Element Client")
EndFunc
Func rename_2()
GUICtrlSetData ($Input1,"Element Client2")
EndFunc
Func rename_3()
GUICtrlSetData ($Input1,"Element Client3")
EndFunc
Func rename_4()
GUICtrlSetData ($Input1,"Element Client4")
EndFunc
Func rename_5()
GUICtrlSetData ($Input1,"Element Client5")
EndFunc
Func rename_6()
GUICtrlSetData ($Input2,"Element Client2")
EndFunc
Func rename_7()
GUICtrlSetData ($Input2,"Element Client3")
EndFunc
Func rename_8()
GUICtrlSetData ($Input2,"Element Client4")
EndFunc
Func rename_9()
GUICtrlSetData ($Input2,"Element Client5")
EndFunc
Func rename_10()
GUICtrlSetData ($Input2,"Element Client6")
EndFunc
Func exit_()
Exit
EndFunc