VCL Memory Data
- 2 minutes to read
VCL Memory Data is a memory-based dataset designed as a temporary storage for data-aware VCL controls. The following screenshot shows the component’s design-time data editor:
Populate a Dataset with Data
You can use the Field Editor dialog to manage fields in the Memory Data component. Double-click the component or click “Field Editor” in its context menu to invoke the dialog.
A click on the Add button invokes the New Field dialog that allows you to create a new dataset field from scratch.
You should specify the following data for a new field:
- Field Name
- Size (for string fields only)
- Lookup definition (for lookup fields only)
Once you create all fields, populate them with data. Click Persistent Editor in the component’s context menu to open the dialog.
Click the last data record and enter values in the required format (string, integer, date, or other). Press the Down Arrow key to add a new record as shown below.
Click OK to apply changes to your dataset. Note that all pending changes are discarded if you close the dialog or click Cancel.
You can use the component’s Persistent Editor dialog to manage data in your dataset.
You can perform the following actions:
- Add dataset records.
- Load fields from a text or binary file.
- Populate the loaded fields with data. Use the same file to load fields and their data. Otherwise, the component replaces the previously loaded fields with fields from a newly selected file.
- Save a dataset to a file.
- Accept all changes applied to your dataset. A click on OK also creates a field component for each field.
- Clear the dataset.
You can sort data records against any number of dataset fields in ascending or descending order. Refer to the following property descriptions for more information:
You can also do the following to filter dataset content: