#include <GUIConstantsEx.au3>
Opt ('MustDeclareVars', 1)
Local $action
Local $gui = GUICreate ("coord", 100, 100)
Local $label = GUICtrlCreateLabel ("", 5, 5, 80, 25)
GUISetState (@SW_SHOW, $gui)
Func _update ()
Local $_coord = MouseGetPos ()
GUICtrlSetData ($label, $_coord[0] &"x"& $_coord[1])
EndFunc
While True
$action = GUIGetMsg ()
_update ()
If $action = $GUI_EVENT_CLOSE Then ExitLoop
WEnd