NOTEBOOK Statement
Syntax:
NOTEBOOK id, x, y, width, height[, style]
The NOTEBOOK statement creates a notebook control within the dialog window.
This control is used to organize information on individual pages so that
it can be located and displayed easily. The NOTEBOOK statement defines the
identifier, position, dimensions, and attributes of a notebook control.
The predefined class for this control is WC_NOTEBOOK. If you do not specify
a style, the default style is WS_TABSTOP and WS_VISIBLE.
id
Specifies the control identifier. The value
is a signed integer -32768 through 32767, an unsigned integer in the range
of 1 through 65535, or a simple expression that evaluates to a value in
these ranges.
x
Specifies the x-coordinate of the lower-left
corner of the control. The value is a signed integer -32768 through 32767
or an expression consisting of integers and the addition (+) or subtraction
(-) operator. The coordinate is assumed to be in dialog units and is relative
to the origin of the dialog window.
y
Specifies the y-coordinate of the lower-left
corner of the control. The value is a signed integer -32768 through 32767
or an expression consisting of integers and the addition (+) or subtraction
(-) operator. The coordinate is assumed to be in dialog units and is relative
to the origin of the dialog window.
width
Specifies the width of the control. The
value is any integer 0 through 65535 or an expression consisting of integers
and the addition (+) or subtraction (-) operator. The width is in n-character
units.
height
Specifies the height of the control.
The value is any integer 0 through 65535 or an expression consisting of
integers and the addition (+) or subtraction (-) operator. The height is
in 1/8-character units.
style
Specifies the control styles. This value
can be a combination of the styles specified for WC_NOTEBOOK. You can use
the bitwise OR ( | ) operator to combine styles.
Comments
The NOTEBOOK statement is used only in a DIALOG or WINDOW statement.
Example
This example creates a notebook control at position (20, 20) within the
dialog window. The notebook has a width of 200 character units and a height
of 50 character units. Its resource identifier is 201. The tabs style BKS_ROUNDEDTABS
specification overrides the notebook default style of square tabs. The default
styles WS_TABSTOP and WS_GROUP are both in effect, though only the latter
is specified.
#define IDC_NOTEBOOK 201#define IDD_NOTEBOOKDLG 503
DIALOG "Notebook", IDD_NOTEBOOKDLG, 11, 11, 420, 420, FS_NOBYTEALIGN |
WS_VISIBLE, FCF_SYSMENU | FCF_TITLEBAR
BEGIN
NOTEBOOK IDC_NOTEBOOK, 20, 20, 200, 400, BKS_ROUNDEDTABS | WS_GROUP
END
[Back: MLE Statement]
[Next: POINTER Statement]