Page 269 - Excel Progamming Weekend Crash Course
P. 269
n540629 ch19.qxd 9/2/03 9:35 AM Page 244
244 Saturday Evening
BorderStyle. Set to fmBorderStyleSingle or fmBorderStyleNone.
Caption. The text displayed in the form’s title bar.
Font. The default for text on the form. See Session 14 for more details on working
with fonts.
ForeColor. The color used for text and drawing on the form. In code, set this prop-
erty with an RGB value.
SpecialEffect. Controls the overall look of the form’s interior. See Table 19-1 for
permitted settings.
Table 19-1 Settings for the UserForm Object’s SpecialEffect Property
Constant Form Interior Appearance
fmSpecialEffectFlat Flat
fmSpecialEffectRaised Raised
frmSpecialEffectSunken Sunken (recessed)
fromSpecialEffectEtched Carved border
frmSpecialEffectBump Ridge on the bottom and right edges, flat on other edges.
Behavior and Position Properties
These form properties control behavior, size, and position:
Height. The form height in points.
Left. The distance from the left edge of the screen to the left edge of the form, in
points.
ShowModal. If True (the default), the user must close the user form before any other
code is executed and before using any other part of the application. If False, the
user can switch away from the form while it is still displayed and use other parts of
the application (such as another form).
StartUpPosition. The position of the form when first displayed. See Table 19-2 for
permitted settings.
Top. The distance from the top of the screen to the top of the form, in points.
Width. The form width in points.
Note that the Top and Left properties affect the initial position of the form only when
the StartUpPosition property is set to Manual; however, after the form is displayed,
changing these properties in code moves the form.