Using Windows Forms controls set 16.14.60.24, I can't make ControlGrid cells have expected click behavior when set to MonthCalendar or ComboBox CellType, for example. I must be missing something simple, but even though I've tried the example code and various variations on them, I still get the same result: No controls pop up when the grid cell is clicked. My GridControl show that the display is doing expected things, but that's about it. Also, the Format setting for the cell also has no effect. (The date string in my code is displayed as a long date format (with HH:mm:ss etc.)) Here is some example C# code from my project:
// testing values:
int colDOB = 6; // an int for the column.
int i = 1; // an int for the row.
// grid is GridControl
GridStyleInfo monthCalendar = new GridStyleInfo();
monthCalendar.CellType = GridCellTypeName.MonthCalendar;
monthCalendar.CellValueType = typeof(System.DateTime);
monthCalendar.Format = "MM/dd/yyyy";
grid[i, colDOB].CellType = GridCellTypeName.MonthCalendar;
// a simple date for testing:
string cellDate = "02/12/2000"; // a test value.
DateTime dT;
if (DateTime.TryParse(cellDate, out dT))
{
monthCalendar.CellValue = dT;
}
else
{
monthCalendar.CellValue = DateTime.MinValue;
}
grid[i, colDOB] = monthCalendar;
// same behavior if next line omitted:
grid.ChangeCells(GridRangeInfo.Cells(i, colDOB, i, colDOB),new GridStyleInfo[] { monthCalendar }, Syncfusion.Styles.StyleModifyType.Override);
Anything look odd here?
Bob