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.
Unfortunately, activation email could not send to your email. Please try again.

GridGroupingControl Cell = "Control"

Thread ID:

Created:

Updated:

Platform:

Replies:

46808 Jul 20,2006 07:44 PM Jul 21,2006 07:22 AM Windows Forms 1
loading
Tags: GridControl
Ken
Asked On July 20, 2006 07:44 PM

Hi,
I''ve customerized DataTimePickerAdv for
column in the GridGroupingControl.
Here is part the code:

DateTimeePickerAdv dateTimePicker = new DateTimePickerAdv();
dateTimePicker.ShowDropButton = false;
dateTimePicker.ShowUpDown = true;
dateTimePicker.ShowCheckBox = false;
dateTimePicker.Format = DateTimePickerFormat.Custom;
dateTimePicker.CustomFormat = fmt;

GridTableDescriptor td = ggcControl.TableDescriptor;

GridColumnDescriptor cd = td.GetColumnDescriptor(columnName);

cd.Appearance.AnyRecordFieldCell.Format = "HH:mm";

cd.Appearance.AnyRecordFieldCell.Control = dateTimePicker;
dd.Appearance.AnyRecordFieldCell.CellType = "Control";
cd.Appearance.AnyRecordFieldCell.CellValueType = typeof(DateTime);

I found two problems (or bugs)
1) It does not poppulate the correct time value
And two row (I only two rows in the table)
always show the same values.

2) Whenever I changed one row to some other time
say 11:33 to 12:56,
the other row will automatically get updated
to the 12:56

Did you miss anything or this is a known bug.

Administrator [Syncfusion]
Replied On July 21, 2006 07:22 AM

Hi Ken,

To have a DataTimePicker in the grid, a custom cell control has to be created that is derived from the GridStaticCellModel and the GridStaticCellRenderer. The custom model thus created can be added through gridGroupingControl1.TableModel.CellModels collection.
Please refer the sample link below, that demonstrates the way you could implement this with the gridgroupingcontrol.

Here is a sample
http://www.syncfusion.com/Support/user/uploads/GGC_DateTimePicker_6cc6efec.zip

Let me know if you need any further assistance.
Regards,
Rajagopal

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;