We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Use Mask Edit Cell Style in a Grid Grouping control

When using the cell style Mask Edit for a cell in a data grid (Grid grouping control), the formatting works fine in terms of the GUI, i.e. a user can type in 05292009 which is placed in a 05-29-2009 mask. However, upon clicking enter, the value does not get saved. Getting the record leaves the field blank. Here is how we set the cell style:

in QueryCellStyleInfo:
e As Syncfusion.Windows.Forms.Grid.Grouping.GridTableCellStyleInfoEventArgs

e.Style.CellType = "MaskEdit"
e.Style.ReadOnly = False
e.Style.Format = "MM-dd-yyyy"
.Style.MaskEdit.Mask = "99-99-9999"

in TableControlCurrentCellEditingComplete:
Dim rec As Record = Me.ggcSchedulerID.Table.DisplayElements(e.TableControl.CurrentCell.RowIndex).ParentRecord

If Not e.TableControl.CurrentCell.Model.Description Is Nothing Then
Me.DtQuery.Rows(introwindex).Item("SCH_DATE") = rec.GetValue("SCH_DATE").ToString


*Note also that the e.TableControl.CurrentCell.Model.Description gets a value of Nothing while using a cell style of TextBox or DateTimePicker enables us to get a Description value.

Are we missing setting something? Thoughts oon this will be greatly appreciated. I am using VB.NET.

1 Reply

LS Lingaraj S Syncfusion Team June 3, 2009 03:37 PM UTC

Hi Karver,

Thank you for your interest in Syncfusion product.

I am unable to reproduce the issue in GridGroupingControl, when the current cell record value has been retrieved in TableControlCurrentCellEditingComplete event. I have tried with created sample with your mentioned code. Also I have attached the sample in below link:
http://files.syncfusion.com/support/samples/Grid.Windows/Forums/GGCRecord.zip

Please let me know if still face the issue, try reproduce the steps in this sample it would be helpful to analyze the more details on the issue.

Regards,
Lingaraj S.

Loader.
Live Chat Icon For mobile
Up arrow icon