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. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Values being lost in Cell

Thread ID:

Created:

Updated:

Platform:

Replies:

20263 Oct 13,2004 12:23 PM UTC Oct 13,2004 01:15 PM UTC WinForms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On October 13, 2004 12:23 PM UTC

I''ve created a drop down combo box model and renderer for a custom combo box that we''re using. For some reason, it appears to have trouble saving the value. I have a checkbox that works in the same way that doesn''t have this problem and I can''t figure it out. I handle the SelectedIndexChanged event in the renderer as follows: private void EditComboBoxSelectedIndexChanged(object sender, System.EventArgs e) { // We need to ignore the messages we get while drawing is taking place. if (inDraw_) { return; } if (base.NotifyCurrentCellChanging()) { MozartGrid grid = this.Grid as MozartGrid; GridStyleInfo style = grid[grid.CurrentCell.RowIndex, grid.CurrentCell.ColIndex]; style.CellValue = editComboBox_.SelectedValue; base.NotifyCurrentCellChanged(); } } I also tried simply setting ControlValue = editComboBox_.SelectedValue, but I wasn''t entirely sure which was the best way to go. Either way produces the same result. After changing the selection in the combo box, when the OnDraw comes around, the CellValue is set to an empty string, not the value that that was placed into the style in the SelectedIndexChanged event. I have no other place in my code that "should" be modifying the value, though I''m certainly open to that possibility. I was just hoping maybe the above code might be the culprit and you guys may see where I''m screwing up. Thanks.

Administrator [Syncfusion]
Replied On October 13, 2004 01:15 PM UTC

I solved the problem. It looks like I wasn''t handling ApplyFormattedText() properly.

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.

Warning Icon 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.Close Icon

;