Skip to main content

TcxGridItemDataBinding.ValueTypeClass Property

Determines the data type which the data binding provides.

Declaration

property ValueTypeClass: TcxValueTypeClass read; write;

Property Value

Type
TcxValueTypeClass

Remarks

The ValueTypeClass property specifies the data type which the data binding provides, thus determining the type of value an item represents. Usually, you should only set ValueTypeClass for the unbound and provider modes. This provides correct memory allocation, validation and sorting of item values. The ValueType property specifies the string representation of the data type. This property can be used to set an item’s data type at design time.

In bound mode, the ValueTypeClass and ValueType properties are assigned automatically based on the field type. To create an unbound item of the specified type in your data-aware Views, customize these properties as needed. This also requires the DataBinding.FieldName property to be unassigned, the DataController.DataModeController.SmartRefresh property be set to True and the DataController.KeyFieldNames property to have a value.

For unbound items, the ValueTypeClass and ValueType properties also determine the type of the default editor used to edit the contents of the item. For instance, assigning ValueTypeClass to TcxBooleanValueType results in using the TcxCheckBox editor for the item. See to the TcxValueType class topic for more details.

For items in bound mode, the default item editor is determined by the field type. Refer to the FieldName property description.

See Also