Copy Pasting a range into a matched row...

omairhe

Well-known Member
Joined
Mar 26, 2009
Messages
2,040
Office Version
  1. 2019
Platform
  1. Windows
Hello Excel Gurus,

How are you today? Please, I need your expertise on this one. In cell B3 is a value between 1 to 200 , and in range B10:B20 are values somewhere between 1 to 200 as well. I need a code that will match the value of B3 with B10:B20.

If a match is found then copy range E3:H3 and paste values only to the matched row and column E:H

For instance...

Prior to running macro.
B15 = 5
E15 = Blank
F15 = Blank
G15 = Blank
H15 = Blank

B3 = 5
E3 = ABC
F3 = DEF
G3 = GHI
H3 = JKL

Macro manually triggered.
B15 = 5
E15 = ABC
F15 = DEF
G15 = GHI
H15 = JKL

Note:
If data already exist then overwrite.
If no match found then exit sub.

Will appreciate plenty and thanks in advance.
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)

Forum statistics

Threads
1,215,061
Messages
6,122,921
Members
449,094
Latest member
teemeren

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