API Documentation > CorelDRAW > 2025-v26 > AppWindow > IVGAppWindow
AppWindow.WindowState property
Gets or sets the application's window state
Syntax:
Property Get WindowState() As cdrWindowState
Property Let WindowState(ByVal Value As cdrWindowState)
Remarks:
The WindowState property returns or specifies the current window state of the CorelDRAW main application window. This window can be minimized, maximized or in a normal state.
Examples:
The following VBA example begins with the application window maximized, sets the current window state to minimized, and displays a message that the window has been minimized. The main application window is then restored to a maximized state.
Sub AppWindowWindowState()
Dim state As cdrWindowState
state = cdrWindowMaximized
AppWindow.WindowState = cdrWindowMinimized
MsgBox "CorelDRAW is now minimized."
AppWindow.WindowState = state 
End Sub