[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Forms' (#lcl)

# TScrollBox.SetParentBackground

Sets the value for the ParentBackground property.

## Declaration

Source position: forms.pp line 218

`protected procedure TScrollBox.SetParentBackground(`
`const AParentBackground: Boolean`
`); override;`

## Arguments

`AParentBackground` |  | New value for the ParentBackground property.

## Description

SetParentBackground is an overridden method in TScrollBox which implements the write access specifier for the ParentBackground property. It calls the inherited method on entry to update the values in the ControlStyle property and invalidate the control. It calls the UpdateParentColorChange method to include or exclude csOpaque as needed in ControlStyle; the value is included when ParentBackground is changed to True.

## See also

TScrollBox.ParentBackground |  | Indicates if the control uses the background from its Parent control.
TScrollBox.UpdateParentColorChange |  | Updates ControlStyle flags to set the opacity for the control.
TControl.SetParentBackground