#include "AFKUdf.au3"

GUICreate("Afk UDF", 200, 50)
$Label = GUICtrlCreateLabel("Du bist da!", 75, 10, 50, 50)
GUISetState(@SW_SHOW)

_AFK_Startup(1, "There", "Away")

While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case -3
			_AFK_Shutdown()
			Exit

	EndSwitch
WEnd

Func There()
	GUICtrlSetData($Label, "Du bist da!")
EndFunc   ;==>There

Func Away()
	GUICtrlSetData($Label, "Du bist weg!")
EndFunc   ;==>Away
