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

Deselect all in ColumnChooser don't disable the "Ok" button

Actual result

The 'OK' button is applicable on the 'Columns menu' after deselecting the 'Select All'

Expected result

The 'OK' button is not applicable on the 'Columns menu' after deselecting the 'Select All'

How can I implement that?Screenshot_2.png

3 Replies 1 reply marked as answer

SI Santhosh Iruthayaraj Syncfusion Team April 5, 2023 12:02 PM UTC

Hi Semenii,

Greetings from Syncfusion support.

We're glad to inform you that we've found a solution to your query using the columnMenuModule. Here is the code snippet that can help you achieve your requirement:



    let grid;


    function created() {

        grid.columnChooserModule.dlgDiv.addEventListener("click", (args) => {

            if (grid.columnChooserModule.mainDiv.getElementsByClassName("e-chk-hidden")[0].getAttribute('aria-checked') === "false") {

                grid.columnChooserModule.dlgObj.btnObj[0].disabled = true;

            } else {

                grid.columnChooserModule.dlgObj.btnObj[0].disabled = false;





<GridComponent ref={ g => grid = g } id="grid" dataSource={data} allowPaging={true} showColumnChooser={true} toolbar={toolbarOptions} pageSettings={{ pageCount: 5, pageSize: 5 }} created={created}>


Additionally, we've prepared a sample using the above code snippet that you can refer to:

Sample: https://stackblitz.com/edit/react-zoxf6p?file=index.js

Please let us know if you have any further queries.


Santhosh I

Marked as answer

DS Daria Semenii April 6, 2023 08:00 AM UTC


Thank you very much for your quick reply.

This solution helped me

SG Suganya Gopinath Syncfusion Team April 9, 2023 08:39 PM UTC

Hi Daria,

We are glad that the provided solution helped to solve the issue. Please get back to us for further assistance. 

We are marking this thread as solved.  

Live Chat Icon For mobile
Up arrow icon