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: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Dropdownlist in Grid Edit Module

Thread ID:

Created:

Updated:

Platform:

Replies:

143599 Mar 28,2019 12:43 PM UTC Mar 29,2019 10:10 AM UTC JavaScript - EJ 2 1
loading
Tags: Grid
Miguel Varela Rodriguez
Asked On March 28, 2019 12:43 PM UTC

Hi, 

i have a DataGrid Column that in edit mode shows a dropdown. This works perfect.

The problem is when i activate Filtering. in this case the dropdown closes directly when i interacst with the list ( click or type ). And dosent show the entries.

I leave my Grid declaration that includes the edit mode, ( its the field codeProject ).

Thank you and greets.



Attachment: Grid_DropDown_code_7b533dd8.zip

Pavithra Subramaniyam [Syncfusion]
Replied On March 29, 2019 10:10 AM UTC

Hi Miguel, 
 
Greetings from Syncfusion. 
 
Query: i have a DataGrid Column that in edit mode shows a dropdown. This works perfect. The problem is when i activate Filtering. in this case the dropdown closes directly when i interacst with the list ( click or type ). And dosent show the entries. 
 
We have validated your query and tried to reproduce the reported problem at our end. But It works fine. We have prepared a sample based on your requirement. Please find the below code example and sample for your reference. 
 
[code example] 
... 
 
    var dropDownData = [ 
        { sid: '1', sname: 'France' }, 
        ... 
   ]; 
 
    var grid = new ej.grids.Grid({ 
        dataSource: window.orderData, 
        editSettings: { allowEditing: true, allowAdding: true, allowDeleting: true, mode: 'Batch' }, 
        allowPaging: true, 
        pageSettings: { pageCount: 5 }, 
        toolbar: ['Add', 'Delete', 'Update', 'Cancel'], 
        columns: [ 
            ... 
           { 
                field: 'ShipCountry', headerText: 'Ship Country', edit: { 
                    create: function () { 
                        elem = document.createElement('input'); 
                        return elem; 
                    }, 
                    read: function () { 
                        return dropDownObj.value; 
                    }, 
                    destroy: function () { 
                        dropDownObj.destroy(); 
                    }, 
                    write: function (args) { 
                        dropDownObj = new ej.dropdowns.DropDownList({ 
                            dataSource: dropDownData, 
                            fields: { text: 'sname', value: 'sname' }, 
                            value: args.rowData[args.column.field], 
                            popupHeight: '230px', 
                            allowFiltering: true, 
                        }); 
                        dropDownObj.appendTo(elem); 
                    } 
                }, width: 150 
            } 
        ], 
    }); 
    grid.appendTo('#Grid'); 
 
 
Please get back to us if you need further assistance. 
 
Regards, 
Pavithra S. 
 


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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

Live Chat Icon For mobile
Live Chat Icon