Unit 'RttiUtils' Package
[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] [#fcl]

TPropsStorage.StoreObjectsProps

Store a list of component properties.

Declaration

Source position: rttiutils.pp line 125

public procedure TPropsStorage.StoreObjectsProps(

  AComponent: TComponent;

  StoredList: TStrings

);

Arguments

AComponent

  

Owner component of the components.

StoredList

  

List of components and their properties to load.

Description

StoreObjectsProps stores a list of component properties, relative to AComponent: the names of the component properties to store are specified as follows:

ComponentName1.PropertyName
ComponentName2.Subcomponent1.PropertyName

The component instances will be located relative to AComponent, and must therefore be names of components owned by AComponent, followed by a valid property of these components. If the componentname is missing, the property name will be assumed to be a property of AComponent itself.

The Objects property of the stringlist should be filled with the instances of the components the property references refer to: they can be filled with the UpdateStoredList call.

For example, to store the checked state of a checkbox named 'CBCheckMe' and the caption of a button named 'BPressMe', both owned by a form, the following strings should be passed:

CBCheckMe.Checked
BPressMe.Caption

and the ACompontent should be the form component that owns the button and checkbox.

Note that this call removes the value of the AObject property.

See also

UpdateStoredList

  

Update a stringlist with object references.

LoadObjectsProps

  

Load a list of component properties.

LoadProperties

  

Load a list of properties.

LoadAnyProperty

  

Load a property value.


Documentation generated on: Dec 22 2024