RestoreControlsVisibilityFromDefaults Method
- Last UpdatedNov 06, 2025
- 1 minute read
The RestoreControlsVisibilityFromDefaults() method retrieves a DataSet containing default values for each label on the specified form. It then finds the controls named in the DataSet and sets their visibility based on the value in the DataSet. The Tag property of the control is also set as the visibility of the label is stored. The control associated with that label must have the same name as the label, excluding the first three characters.
public static void RestoreControlsVisibilityFromDefaults(
string screen,
string sectn,
Control containerControl
)
Parameters
- screen
- Required. Holds the screen from which the label values were taken.
- sectn
Required. Holds the section to which the label values belong.
- containerControl
- Required. Holds the container control being set up.