copy and paste cells to different column based on conditions

myjebay1

New Member
Joined
Jun 15, 2012
Messages
5
hey all

having a little trouble with this one shouldn't be too difficult..

basically if column B has a value then copy that value and the corresponding values in column A and C into column G H and I respectively.
(A-->G B-->H and C-->I)

if column B is empty then check column E for a value. If column E has a value then copy the value of columns D E and F into G H and I respectively.
(D-->G E-->H F-->I)

If both columns B and E are empty then skip to the next line which has a value in B OR E.

THANKS SO MUCH

best wishes as always,

jebay


thanks again!
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
In G2, place:

Code:
=IF($B2="",IF(E2="","",D2),A2)

Then drag it across and down. Should do the trick.

Hope this helps.
 
Upvote 0
thanks so much, just one thing how do you delete all the rows in GHI which dont have any values in them?
 
Upvote 0

Forum statistics

Threads
1,207,260
Messages
6,077,351
Members
446,279
Latest member
hoangquan2310

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