Creates a new Gui object, which is essential for creating and managing a GUI.

GuiObj := GuiCreate(Options, Title := A_ScriptName, EventObj)



This parameter can contain any of the options supported by Gui.Opt.


The window title. If omitted, it defaults to the current value of A_ScriptName.


An "event sink", or object to bind events to. If EventObj is specified, OnEvent, OnNotify and OnCommand can be used to register methods of EventObj to be called when an event is raised. If omitted or empty, any string passed to OnEvent's Function parameter is interpreted as a function name.

Return Value

Returns a Gui object. This object provides methods and properties for creating and managing windows, and creating controls.


Gui object, GuiControl object, GuiFromHwnd, GuiCtrlFromHwnd, Control Types, ListView, TreeView, Menu object, Control functions, MsgBox, FileSelect, DirSelect