Copying a whole row, only paste certain values

nyconfidential

New Member
Joined
Jul 22, 2015
Messages
46
Office Version
  1. 365
  2. 2016
Hi all - I have a user who pastes an entire row of values from a csv into an xlsx file. This was fine initially, but there are now a few columns we DON'T want to paste data into (ex - we copy a row from the CSV that does from column A to Z, we want to paste the data into every column in the xlsx except for column, D, E and F).

I guess my question is - Is there a way to specify which columns to paste after the entire range has been copied to the clipboard? Example - paste columns A-C, don't paste D-F, paste E-Z. I know could use that "Union" function when copying but I'd rather not have to convert the csv into an xlsx -trying to keep this as simple as possible for the user. Thanks in advance...
 

Some videos you may like

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

GWteB

Well-known Member
Joined
Sep 10, 2010
Messages
1,284
Office Version
  1. 2013
Platform
  1. Windows
Is there a way to specify which columns to paste after the entire range has been copied to the clipboard?
As far as I know, this possibility does not exist. In this case I would use a temporary worksheet. Copy the original and (except for a few columns) to be replaced row in its entirety to this temporary worksheet. Paste the CSV data in there and then copy the cells of those few columns from the original row to the new row on the temporary worksheet. Finally, copy that row (back) to the original row on the original worksheet. This is one of the possible ways to go about this, but I am afraid you will have to write some necessary code to force the user in such a way that no data is lost.
 

NeoSez

Board Regular
Joined
Aug 14, 2020
Messages
128
Office Version
  1. 2019
  2. 2010
Platform
  1. Windows
Hi all - I have a user who pastes an entire row of values from a csv into an xlsx file. This was fine initially, but there are now a few columns we DON'T want to paste data into (ex - we copy a row from the CSV that does from column A to Z, we want to paste the data into every column in the xlsx except for column, D, E and F).

I guess my question is - Is there a way to specify which columns to paste after the entire range has been copied to the clipboard? Example - paste columns A-C, don't paste D-F, paste E-Z. I know could use that "Union" function when copying but I'd rather not have to convert the csv into an xlsx -trying to keep this as simple as possible for the user. Thanks in advance...
are you copying all rows or only selected rows?
There is a way to copy only certain columns, but it will copy all the rows in the sheet. But you can copy the selected data to a sheet and then copy the select rows.
 

Watch MrExcel Video

Forum statistics

Threads
1,118,279
Messages
5,571,283
Members
412,375
Latest member
BRJoeyMelo
Top