Microsoft KB Archive/100715

From BetaArchive Wiki
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Knowledge Base


Error Message "That Command Cannot Be Used on Multiple Selections"

Article ID: 100715

Article Last Modified on 8/15/2003



APPLIES TO

  • Microsoft Excel 97 Standard Edition



This article was previously published under Q100715

SYMPTOMS

In Microsoft Excel, when you attempt to copy nonadjacent cell selections, you may receive one of the following error messages.

Microsoft Excel 97 for Windows

That command cannot be used on multiple selections.

Microsoft Excel Versions 4.0, 5.0 and 7.0

Cannot do that command on nonadjacent selections

Microsoft Excel Versions 3.0 and Earlier

Can't do that command on a multiple selection

CAUSE

These error messages may occur when your cell or range selections are in different columns or different rows. You can, however, copy and paste nonadjacent ranges without an error message if your selection contains any of the following:

  • Multiple rows within the same column, for example, A1, A3, A5
  • Multiple columns within the same row, for example, A2, C2, E2
  • Multiple rows and columns within the same columns and rows, for example, A1, C1, A3, C3, A5, C5

NOTE: This message also occurs if nonadjacent sheets are selected in a Microsoft Excel 5.0 or later workbook, and you are pasting to another workbook.


MORE INFORMATION

When you make a nonadjacent selection and then click Copy on the Edit menu, Microsoft Excel tries to identify an outline type of the selection. Because Microsoft Excel "slides" the ranges together and pastes them as a single rectangle, a contiguous rectangle must remain if the rows and columns in between the selected cells are collapsed or set to a size of 0.

For example if you wanted to perform an operation on the following sample data

   A1: 1   B1:     C1: 2
   A2:     B2:     C2:
   A3: 3   B3:     C3: 4
                

because a contiguous rectangle remains if you were to collapse row 2 and column B, you can individually select cells A1, C1, A3, C3 and copy them without error. [To make a nonadjacent selection, hold down the CTRL key (or the COMMAND key if you are using Microsoft Excel for the Macintosh) while selecting additional cells or ranges.]

This selection will be pasted as a single rectangle:

   A5: 1  B5: 2
   A6: 3  B6: 4
                

However, you cannot add cell B2 to this nonadjacent selection, because Microsoft Excel cannot determine which direction you want the cells to slide. For example, B2 could slide between A1 and A3, C1 and C3, A1 and C1 or A3 and C3. This would result in rectangles of varying shapes and sizes. Because you cannot designate how you want the rectangle arranged, Microsoft Excel returns the error message. In this case, the cell range must be a single selection, or the cells must be copied individually.

For additional information, please see the following articles in the Microsoft Knowledge Base:

141763 : XL Err Msg: "Cannot Use That Command on Multiple Selections"


119806 : ACC2: Exporting Data to MS Excel 5.0 or 95 Twice Causes Error



Additional query words: fails errmsg discontiguous export file excel access error Can t do that command on a multiple selection XL

Keywords: kberrmsg kbprb KB100715