SpecialEffect Property
You can use the SpecialEffect property to specify whether special formatting will apply to a section or control.
expression.SpecialEffect
expression Required. An expression that returns one of the objects in the Applies To list.
Remarks
The SpecialEffect property uses the following settings.
Setting | Visual Basic | Description |
---|---|---|
Flat | 0 | The object appears flat and has the system's default colors or custom colors that were set in Design view. |
Raised | 1 | The object has a highlight on the top and left and a shadow on the bottom and right. |
Sunken | 2 | The object has a shadow on the top and left and a highlight on the bottom and right. |
Etched | 3 | The object has a sunken line surrounding the control. |
Shadowed | 4 | The object has a shadow below and to the right of the control. |
Chiseled | 5 | The object has a sunken line below the control. |
You can set this property by using the Special Effect button on the Formatting (Form/Report) toolbar, the object's property sheet, a macro, or Visual Basic.
For controls, you can set the default for this property by using the default control style or the DefaultControl method in Visual Basic.
The SpecialEffect property setting affects related property settings for the BorderStyle, BorderColor, and BorderWidth properties. For example, if the SpecialEffect property is set to Raised, the settings for the BorderStyle, BorderColor, and BorderWidth properties are ignored. In addition, changing or setting the BorderStyle, BorderColor, and BorderWidth properties may cause Microsoft Access to change the SpecialEffect property setting to Flat.
Note When you set the SpecialEffect property of a text box to Shadowed, the vertical height of the text display area is reduced. You can adjust the Height property of the text box to increase the size of the text display area.
Example
The following example sets the appearance of the text box "OrganizationName1" on the "Mailing List" form to raised.
Forms("Mailing List").Controls("OrganizationName1").SpecialEffect = 1