Skip to main content

TdxCustomTileControl.StoreToRegistry(string,Boolean,string) Method

Saves the tile control’s settings to the registry.

Declaration

procedure StoreToRegistry(AStorageName: string; AReCreate: Boolean = True; const ASaveName: string = '');

Parameters

Name Type
AStorageName string
AReCreate Boolean
ASaveName string

Remarks

The StoreTo~ and RestoreFrom~ methods allow you to persist tile control settings across multiple sessions. Call the StoreToRegistry method to save the tile control’s settings to the registry. Later, you can call the RestoreFromRegistry method to apply the stored settings to this or another tile control, restoring its state from the registry.

By default, the stored information includes the following element and layout-specific settings:

You can extend this list with any other settings that need to be persisted by handling the OnGetStoredProperties, OnGetStoredPropertyValue, OnSetStoredPropertyValue, and OnInitStoredObject events.

The AStorageName parameter specifies the full registry path for the stored information. The path is formed by adding the AStorageName subkey to the HKEY_CURRENT_USER key.

The AReCreate parameter determines whether the INI file is recreated with each StoreToRegistry method call. If True is passed as the AReCreate parameter, the existing registry key is deleted and then created again. Otherwise, the key’s subkeys are identified based on the ASaveName parameter value and updated with corresponding settings being stored. The rest of the settings are appended to the key as new subkeys.

For information on the ASaveName parameter, refer to the RestoreFromIniFile method description.

See Also