Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
15
how to create dropdown as column header in iggrid.
posted

Hi all,

I want to display a dropdown (which will have values inside drop down) as column header in iggrid. kindly assist. 

example:

ID   Name  dropdown(values inside dropdown)

  • 80
    Offline posted

    Hello Iswarya S,

    Thanks for posting in our community.

    Do you need to change  column cells when you choose different option from the dropdown?

    You can do something like this:

    var dropdown="<select><option value='volvo'>Volvo</option><option value='opel'>Opel</option>"

    columns: [
    { headerText: "Product ID", key: "ProductID", dataType: "number", width: "15%" },
    { headerText: "Product Name", key: "Name", dataType: "string", width: "40%" },
    { headerText: dropdown,key:"DropDown",dataType:"string"}
    ],

    Also, if you need to change data respectively you can bind to the "onchange" event in the "select" tag to render different data.

    If you need any more help or have additional questions or concerns, please let me know.

    Best Regards,

    Martin Dragnev,

    Infragistics