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

Fill ComboBox on changing Grid row

Hi,

I have a ComboBox 'A' and a grid, in grid their are two columns.One column type is dropdownlist other one is text.

When i enter columns of a row and when i move to next row the value of dropdownlist of grid should be populated dynamically in the ComboBox 'A'.

In the RowValidating event of grid, i am trying to populate the Combobox 'A', it is populating correct for the first row, but for the next rows the object is getting set in the combox box.

Any solution for this?



1 Reply

HA haneefm Syncfusion Team July 12, 2007 03:38 PM UTC

Hi Raghav,

You can use the CurrentCellShowingDropDown event to set values into a droplist. If you have a list of strings you want to use as the drop values, then you can use a StringCollection object and set it as the ChoiceList property of the cell style.

Here is a sample that changes the ChoiceList shown in column 2 based on the value set in column 1 using CurrentCellShowingDropDown. You can see other choicelist usage in the Grid\Samples\CellTypes\ComboBoxes sample. There is also a KB on dynamic combobox lists though it uses DataTables and not choicelists.http://www.syncfusion.com/Support/article.aspx?id=567'>http://www.syncfusion.com/Support/article.aspx?id=567">http://www.syncfusion.com/Support/article.aspx?id=567

Best regards,
Haneef

Loader.
Live Chat Icon For mobile
Up arrow icon