|Navigation: Language Reference > 9 - Window and Report Attributes > Window and Report Attributes >====== CENTER (set centered window position) ======|
The CENTER attribute (PROP:CENTER) indicates that the window's default position is centered. A WINDOW structure with the MDI attribute is centered on the APPLICATION. An APPLICATION structure is centered on the screen. A non-MDI WINDOW is centered on its parent (the window currently with focus when the non-MDI WINDOW is opened).
This attribute has no meaning unless at least one parameter of the AT attribute is omitted. This means that the CENTER attribute provides a default value for any omitted AT parameter.
For multi-monitor systems: Child and Owned Windows with the CENTER attribute (or PROP:CENTER = TRUE) applied are centered in the client area of their Parent/Owner window. Other windows with the CENTER attribute applied are centered in the monitor where most parts of the previous window in the same thread are displayed; if there are no other windows in the same thread, the window is displayed in the primary monitor.
WinOne WINDOW,AT(,,380,200),MDI,CENTER !Window centered relative to application frame
WinTwo WINDOW,AT(,,380,200),CENTER !Window centered relative to its parent: