VBA to find/replace information from one sheet to another

dominikapabis

New Member
Joined
Feb 9, 2016
Messages
4
Hello,

I am looking for help on writing a VBA that will replace information in one sheet using a legend that is in another sheet.

I need two things to happen.
1. replace cells in column C in Sheet1 with data from column C in Sheet2 if column C in Sheet1 = column A in Sheet2.
2. also insert the adjacent cell (Item Number) that corresponds with the new description.

Here is a simple sample of the spreadsheet.

Sheet 1 BEFORE Code:
1
ABC
2EQUIPMENT TYPEITEM NUMBERDESCRIPTION
3Actives NC400
4Full Spectrum EQ- Bank 1T2&4 CS12
5T2&4 CS09
6Full Spectrum EQ - Bank 2T8 CS09
7T8 CS06

<tbody>
</tbody>


Sheet 2 (KEY)
1
ABC
2Original DescriptionItem NumberNew Description
3
NC400​
5543
Full Features 2x2
4
T2&4 CS12​
5568Cable Simulator 12db
5
T2&4 CS09​
9956Cable Simulator 9db
6
T8 CS09​
5547Return Path 9db
7
T8 CS06​
6689Return Path 6db

<tbody>
</tbody>


Sheet 1 AFTER CODE:
1
ABC
2EQUIPMENT TYPEITEM NUMBERDESCRIPTION
3Actives 5543Full Features 2x2
4Full Spectrum EQ- Bank 15568Cable Simulator 12db
59956
Cable Simulator 9db
6Full Spectrum EQ - Bank 25547Return Path 9db
76689Return Path 6db

<tbody>
</tbody>


I know that I will have to use a series of loops, I would appreciate any help.

Thanks!`
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.

Forum statistics

Threads
1,214,788
Messages
6,121,600
Members
449,038
Latest member
Arbind kumar

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