Window Creation

An application creates its windows (including the main window) by using the CreateWindow or CreateWindowEx function and providing the information required to define the attributes of the window. CreateWindowEx has a parameter, dwExStyle, that CreateWindow does not have; otherwise, the functions are identical. In fact, CreateWindow simply calls CreateWindowEx, setting the dwExStyle parameter to zero. For this reason, the remainder of this overview refers only to CreateWindowEx.

There are additional functions — including DialogBox, CreateDialog, and MessageBox — for creating special-purpose windows such as dialog boxes and message boxes. For more information, see Dialog Boxes.

This section contains the following topics: