Hi Carlos,
Thanks for using Syncfusion products.
By default, we cannot edit the cell values of RecordPreviewCell at run time. The cell values of the RecordPreviewCells will only be shown as preview. The default cell value of RecordPreviewRow is “Preview”. However, we can change the cell values through QueryCellStyleInfo events. We have already provided dashboard sample regarding this. Please refer to the below sample,
Code Example
//Event Subscription.
this.gridGroupingControl1.QueryCellStyleInfo += new GridTableCellStyleInfoEventHandler(gridGroupingControl1_QueryCellStyleInfo);
// QueryCellInfo even is hooked to set the values.
private void gridGroupingControl1_QueryCellStyleInfo(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableCellStyleInfoEventArgs e)
{
switch (e.TableCellIdentity.TableCellType)
{
case GridTableCellType.RecordPreviewCell:
{
GridGroupingControl groupingControl = (GridGroupingControl)sender;
GridTable table = groupingControl.Table;
GridRecord record = e.TableCellIdentity.DisplayElement.ParentRecord as GridRecord;
if (record != null)
e.Style.CellValue = record.GetValue("Notes").ToString();
else
e.Style.CellValue = "No Notes.";
break;
}
}
}
Dashboard Sample Location
<Installed_Location>\Syncfusion\EssentialStudio\<Version_Number>\Windows\Grid.Grouping.Windows\Samples\Layout Customization\Record Customization Demo\
Regards,
Amal Raj U.