Knowledge base KB0160

Copying a multi-selection of non-adjacent cells fails

Problem

Copying a multi-selection of non-adjacent cells into the think-cell datasheet does not work. When multi-selecting several non-adjacent cells, e.g., by pressing the control key and subsequently clicking on cells, and then copy/pasting these cells into think-cell's internal datasheet, unselected cells in between are pasted as well.

View of the copied and of the pasted multi-selection
  • Source sheet: Cells A1, A3, A5 are copied → Destination sheet: A1:A5 are pasted

Explanation

This is a design limitation of Excel. think-cell's internal datasheet is based on Excel, but is a separate Excel process. The problem can also be reproduced without think-cell when copy/pasting non-adjacent cells into a separate Excel process.

Reproduction without think-cell:

  1. Open Excel and enter some numbers into cells A1 to A5.
  2. Select the cells A1, A3, and A5 by holding the Ctrl key pressed and clicking into these cells (as in above screenshot). Copy the selection.
  3. Start a separate Excel process by right-clicking on the Excel symbol in the task bar and clicking on Microsoft Excel 20… How to start separate Excel process In Excel 2013 and later, keep the ALT key pressed simultaneously to start a separate process. Confirm the Do you want to start a new instance of Excel? message with Yes.
  4. Paste (e.g., by pressing Ctrl + V ).

Result: The unselected cells A2 and A4 are pasted as well.

We have filed this issue with the Microsoft Office Support as case REG:112021442496011. The Microsoft Office Support says that this behavior is not documented so far, but is 'by design'.

“This behavior is by design.

When you use the clipboard for copy and paste, you are using a feature that is designed to work across all office applications. Since this is the case, the clipboard uses HTML code for storing and then pasting data. The HTML code is limited to a range select and you get all the data in the range including the cells you did not select. It is creating a table in HTML code and uses this table for the paste action. This allows the clipboard to share data from Excel to other office applications such as Word, Power Point, and other instances of Excel outside this workbook.

When you use Ctrl-C and then follow it up with Ctrl-V instead of using the clipboard you are using an internal Excel single instance copy feature that allows Excel to copy only the selected cells. This gives you the desired behavior. The clipboard has limits due to the fact that it shares with all office applications. The limit to the clip board was planned due to the huge amount of data that would be required to do a simple copy and paste. Large copy actions would overwhelm the system and cause huge slowdowns in performance. The HTML copy is a stripped down version of the internal copy and therefore there are differences and limits.” (Microsoft Office Support)