Enable copying of text from a grid cell without enabling editing

200 views
Skip to first unread message

ajs123

unread,
May 21, 2013, 5:49:36 AM5/21/13
to param...@googlegroups.com
Hi all,
 
I would like users to be able to use the mouse to highlight some or all of the text within any grid cell and use Ctrl+C to copy it to their clipboard. However, the only way I have found to enable this is to set "editable: true" on my grid, which I don't want to do. Is it possible to allow highlighting/copying of text from a cell without enabling editing?

paramquery

unread,
May 22, 2013, 8:11:37 AM5/22/13
to param...@googlegroups.com
See whether it helps

$("div.pq-grid-inner", $grid).enableSelection();

ajs123

unread,
May 24, 2013, 3:14:18 AM5/24/13
to param...@googlegroups.com
Based on your suggestion, I added the following line immediately after initializing the grid:
 
$("div.pq-grid-inner").enableSelection();
 
It worked perfectly. Many thanks for your help!
Reply all
Reply to author
Forward
0 new messages