Search code examples
devexpressdevextremedx-data-grid

How to copy multiple SELECTED ID from dxDatagrid?


I am having checkbox in dxDatagrid, I want to copy selected ID from dxDatagrid on single click and also i want in comma separated way(I mean selected value or ID should get copied in comma separated way). I tried multiple ways but none work for me.

I hope I made my query clear and its a very challenging question to solve for me. Any help will be appreciated.


Solution

  • you can use selectedRowKeys() method, to get an array of selected rows. FYI: you can also get rows data from getSelectedRowsData()

    read more: https://js.devexpress.com/Documentation/ApiReference/UI_Widgets/dxDataGrid/Methods/#getSelectedRowKeys

    https://js.devexpress.com/Documentation/ApiReference/UI_Widgets/dxDataGrid/Methods/#getSelectedRowsData