ComboBox bind dynamic source based on another column value

Posted by: 1728884346 on 23 May 2018, 1:46 am EST

  • Posted 23 May 2018, 1:46 am EST

    i saw a example as below for winform, any example to achieve this function in web application for ASP.NET MVC?
  • Replied 24 May 2018, 1:04 am EST

    We are looking into this. We will update by tomorrow.

  • Replied 24 May 2018, 11:07 pm EST

    We are sorry for the delayed response.
    Please refer to the following demo sample for the same using DataMap:

  • Replied 29 May 2018, 6:28 pm EST

    Hi Manish,

    thanks, but i have problem when try to use dataMap, success to bind Text to dropdown, but how to get selectedValue ?

    or any way to bind a dynamic model for ComboBox? our original design is use ComboBox.
  • Marked as Answer

    Replied 31 May 2018, 7:17 pm EST

    We are sorry for the delayed response.
    The selectedValue can be get using FlexGrid cell value since DataMap set the cell value.

    However, if you would like to add ComboBox, you need to add ComboBox using ItemFormatter. Please refer to the following script code snippet to add ComboBox:

     function ItemFormatter(panel, r, c, cell) {
    if (panel.cellType == 1 && panel.columns[c].binding == "Country") {
    let div = document.createElement("Div"); = "div" + r + c;
    new wijmo.input.ComboBox(div, {
    itemsSource: panel.rows[r].dataItem.Countries,
    selectedValuePath: "Id",
    selectedIndexChanged: function (s, e) {
    panel.rows[r].dataItem.Country = s.selectedValue;
    console.log(panel.grid.getCellData(r, c));
    cell.innerText = "";

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels