You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched the Github Issues for similar issues, but did not find anything.
Problem
When using a spreadsheet library, users usually need to copy and paste the contents of the table through mouse operations. In some application scenarios, we hope to complete a certain range of copy and paste operations through APIs, such as:
Automatically handle data migration in the background.
Implement automated copy and paste functionality in custom shortcut keys or toolbars.
When integrating complex business logic, avoid relying on user manual operations.
The current library supports copying and pasting through mouse operations, but lacks an API that directly executes this operation through code. Implementing this feature will enhance the flexibility and automation capabilities of developers.
I suggest adding an API for copying and pasting scopes, for example:
Copy: Provides a method for copying the contents of a specified range of cells into memory (similar to a clipboard), supporting Row and Column ranges.
Paste: Provides a method for pasting the contents of a cell saved in memory into a target range.
Functional requirements:
Support simultaneous copying of content and formats (such as color ,font and merge), and allow for individual selection of whether to copy formats.
When the size of the source range and the target range are inconsistent, support circular pasting by row/column, or throw an error.
You can specify whether to cover existing data within the target range through parameters.
Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑🤝🧑👫🧑🏿🤝🧑🏻👩🏾🤝👨🏿👬🏿
Origin Title: [Feature] Request: Support Range Copy-Paste through API
Title: [Feature] Request: Support Range Copy-Paste through API
Initial checklist
Is this really a problem?
I have searched the Github Issues for similar issues, but did not find anything.
Problem
When using a spreadsheet library, users usually need to copy and paste the contents of the table through mouse operations. In some application scenarios, we hope to complete a certain range of copy and paste operations through APIs, such as:
Automatically handle data migration in the background.
Implement automated copy and paste functionality in custom shortcut keys or toolbars.
When integrating complex business logic, avoid relying on user manual operations.
The current library supports copying and pasting through mouse operations, but lacks an API that directly executes this operation through code. Implementing this feature will enhance the flexibility and automation capabilities of developers.
I suggest adding an API for copying and pasting scopes, for example:
Copy: Provides a method for copying the contents of a specified range of cells into memory (similar to a clipboard), supporting Row and Column ranges.
Paste: Provides a method for pasting the contents of a cell saved in memory into a target range.
Functional requirements:
Support simultaneous copying of content and formats (such as color ,font and merge), and allow for individual selection of whether to copy formats.
When the size of the source range and the target range are inconsistent, support circular pasting by row/column, or throw an error.
You can specify whether to cover existing data within the target range through parameters.
Initial checklist
Problem
When using a spreadsheet library, users usually need to copy and paste the contents of the table through mouse operations. In some application scenarios, we hope to complete a certain range of copy and paste operations through APIs, such as:
The current library supports copying and pasting through mouse operations, but lacks an API that directly executes this operation through code. Implementing this feature will enhance the flexibility and automation capabilities of developers.
I suggest adding an API for copying and pasting scopes, for example:
Copy: Provides a method for copying the contents of a specified range of cells into memory (similar to a clipboard), supporting Row and Column ranges.
Paste: Provides a method for pasting the contents of a cell saved in memory into a target range.
Functional requirements:
example pseudocode:
// 假设
sheet是电子表格实例 const range = { startRow: 1, startCol: 1, numRows: 3, numColumns: 3 }; sheet.copyRange(range); // 将范围 (1,1) 到 (3,3) 的所有内容复制
// 粘贴到目标范围 (5,5) 开始的区域 const targetRange = { startRow: 5, startCol: 5 }; sheet.pasteRange(targetRange, { includeFormat: true }); // includeFormat 表示是否同时粘贴格式
The text was updated successfully, but these errors were encountered: