Home > Back-end > Pray about TField function and using method of explanation of this class
Pray about TField function and using method of explanation of this class
Time:10-10
Pray about TField function and using method of explanation of this class
CodePudding user response:
Pascal TField=class (TComponent);
C + + The class TField: public TComponent;
The File The DB
The Description TField encapsulates the fundamental behaviors common to all field components. It introduces the properties, events, and the methods that are 2:
Change the value of a field in a dataset.
Convert the value of a field from one data type to another.
Validate the data that the user enters the for a field.
Define how the data in the field appears as it is displayed or edited.
Calculate the value of a field, the from code written in the OnCalcFields event of the dataset.
Look up the field 's value from another dataset.
Do not create instances of TField. TField descendants are created automatically each time a dataset is activated. These descendants can be dynamic (the default) or persistent, dynamic field components reflect the columns in the physicist metadata at the time a dataset is the opened. The persistent field components are created at design time using the Fields editor, which specifies the Fields in the dataset, their properties, and their ordering.
Creating persistent field components guarantees that each time an application runs, it uses and displays the same columns, in the same order, even if the physical structure of the underlying database changes. If a column on which a persistent field component is based is deleted or changed, the IDE generates an exception rather than opening the dataset against a nonexistent column or mismatched data. If this happens, remove the field component for the nonexistent field using the Fields editor.
A field in A dataset is always treated as one of the following TField descendant classes below: