BoldSignA modern eSignature application with affordable pricing. Sign up today for unlimited document usage!
Hello,
I am trying to copy and paste values from cells while using the "Add"-Interaction in the toolbar.
When I try to copy a value from my selected cell, I get the whole row or an empty string, but I only want the cells, so I can still delete rows.
How can I achieve the copy/paste with using the CellSelectionMode "BoxWithBorder", Type "Multiple" and Mode "Both". ?
Hi Harald,
Greetings from Syncfusion support
Before we start providing solution to your query we would like to inform you about the paste functionality in the Grid. You can able to copy the content of a cell or a group of cells by selecting the cells and pressing Ctrl + C shortcut key and paste it to another set of cells by selecting the cells and pressing Ctrl + V shortcut key. To perform paste functionality, it requires the selection mode to be Cell, cellSelectionMode to be Box and also Batch Editing should be enabled. Please refer the below documentation for more information.
Documentation: https://ej2.syncfusion.com/documentation/grid/clipboard/#paste
https://ej2.syncfusion.com/documentation/grid/clipboard/#limitations-of-paste-functionality
As per your shared information, we have prepared a sample of cellSelectionMode as BoxWithBorder in Batch edit mode it was working fine at our end. Please refer the below code example and sample for more information.
let grid: Grid = new Grid( { dataSource: orderData, selectionSettings: { type: 'Multiple', mode: 'Cell', cellSelectionMode: 'BoxWithBorder' }, editSettings: { allowEditing: true, allowAdding: true, allowDeleting: true, mode: 'Batch' }, allowPaging: true, pageSettings: {pageCount: 5}, toolbar: ['Add', 'Delete', 'Update', 'Cancel'], columns: [ . . . . . . . . . . . . . . . . . . . . . . ], }); grid.appendTo('#Grid');
|
Sample: https://stackblitz.com/edit/2fslrl?file=index.ts
Screenshot:
Regards,
Rajapandi R
Hello,
It does not completly work, even in the example you provided.
Also I can't delete any rows now because of the Cell selector, it tells me that there is no Data for deletion.
Steps to reproduce:
In my project, I even get this error:
TypeError: Cannot read properties of undefined (reading 'getElementsByClassName')
Harald,
We have confirmed and logged this as a bug in the component. So, we have considered ” Copy Paste problems while adding a new row” as a defect and logged a report for the same. We will include the defect fix in any of our upcoming patch release. Until then we appreciate your patience.
You can now track the current status of your request, review the proposed resolution timeline, and contact us for any further inquiries through this link.
Feedback link : https://www.syncfusion.com/feedback/43044/copy-paste-problems-while-adding-a-new-row
Harald,
We are glad to announce that our Essential Javascript2 patch release (v21.2.5) has been rolled out successfully and in that release, we have added the fix for the issue - “Copy Paste problems while adding a new row”. So please update your packages to this version or latest packages version to include this fix.
Feedback: https://www.syncfusion.com/feedback/43044/copy-paste-problems-while-adding-a-new-row
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.