copying and pasting multiple columns to another sheet

benlyon

New Member
Joined
Aug 16, 2013
Messages
1
Hi All, Currently I have some code that looks like this:

Range("A1:A30") = Workbooks(newbooks).Sheets(1).Range("A1:A30").Value
Range("C1:C30") = Workbooks(newbooks).Sheets(1).Range("C1:C30").Value
Range("E1:E30") = Workbooks(newbooks).Sheets(1).Range("E1:E30").Value

This works fine however I want to streamline it further by doing the following:

Range("A1:A30,C1:C30,E1:E30") = Workbooks(newbooks).Sheets(1).Range("A1:A30,C1:C30,E1:E30").Value

Basically I want to save as much code and time as possible by combining everything into a single piece of code, however when I execute this function it does not work as it only returns the value from A1:A30. Can anyone help with this?
Thanks
 

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.

Forum statistics

Threads
1,214,968
Messages
6,122,509
Members
449,089
Latest member
RandomExceller01

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top