Microsoft Office Tutorials and References
In Depth Information
Once you’ve selected the form, you can adjust its size by dragging its borders. Move the
mouse pointer over one of the squares on the border, and the mouse pointer will change to a
double arrow. Click and hold the mouse button while moving the mouse to adjust the size of
the form.
You can also adjust the form’s size in the Properties window. The height of the form is
controlled by the Height property, and its width is controlled by the Width property. These values
are measured in points.
Properties of a UserForm
The UserForm contains a wide range of properties that control how it looks and works. Table
19-1 lists some of the key properties.
Table 19-1. Key Properties of the UserForm Object
Property
Description
BackColor
Contains the color of the background of the form.
Caption
Contains the value displayed in the form’s title.
Enabled
When True , means that the form is available for use.
Height
Specifies the height of the form in points.
Left
Specifies the distance between the left edge of the form and
the left edge of the screen.
Name
Contains the name of the form.
Picture
Displays the specified picture as the background of the form.
ScrollBars
Specifies which scroll bars appear on the form. Can be:
fmScrollBarsNone , fmScrollBarsHorizontal , fmScrollBarsVertical ,
or fmScrollBarsBoth .
StartUpPosition
Determines where the form is displayed on the screen. A value
of 0 means that the Top and Left properties are used to position
the form. A value of 1 means that the form will be displayed on
the center of the Excel application. A value of 2 means that the
form will be displayed in the center of the screen. A value of 3
means that the form will be displayed in the upper-left corner of
the screen.
Top
Specifies the distance between the top of the form and the top
edge of the screen.
Width
Specifies the width of the form in points.
The Name property contains the name of the user form. Remember that this property actu­
ally appears at the top of the list of properties rather than in alphabetical order like the rest of
the properties are listed.
Search JabSto ::




Custom Search