Gets or sets a value indicating whether literal characters in the edit mask are stored to the underlying data source.
[Visual Basic]
Public Property EditMaskUpdate As Boolean
[C#]
public bool EditMaskUpdate {get;set;}
[Delphi]
public property EditMaskUpdate: Boolean read get_EditMaskUpdate write set_EditMaskUpdate;
Remarks
Normally, after the user finishes editing a cell in a column that has its EditMask property set, C1TrueDBGrid caches the modified cell text, but any literal characters in the input mask template will be stripped from the modified cell text beforehand. However, this behavior can be overridden with the EditMaskUpdate property.
By default, the EditMaskUpdate property is set to False. This means that when the modified cell text is updated to the database, the grid sends the cached text (stripped of literals), not the formatted text displayed in the cell. This default behavior can be overridden by setting the EditMaskUpdate property to True, which causes the cached text to be formatted according to the EditMask property before being updated to the database.
Example
The following code uses the EditMaskUpdate property to enable the cached text to be formatted according to the EditMask property before being updated to the database:
Me.C1TrueDBGrid1.Columns(0).EditMaskUpdate = True
· C#
this.c1TrueDBGrid1.Columns[0].EditMaskUpdate = true;
· Delphi
Self.C1TrueDBGrid1.Columns[0].EditMaskUpdate := True;
See Also
C1DataColumn Class | C1DataColumn Members | C1.Win.C1TrueDBGrid Namespace
Send comments about this topic to ComponentOne. Copyright © ComponentOne LLC. All rights reserved. |