Visual Basic Code that does a Vlookup but retains formatting

dab448

New Member
Joined
Aug 21, 2015
Messages
1
Hi Everyone,

I am trying to basically do a Vlookup that can retain the font color and formatting. But as you can't do this with a Vlookup function, I need a Visual Basic function that can do this.

Can anyone help?

Thank you!!
Danielle
 

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.
You need to put this code in the sheet module for the worksheet in which you want to monitor changes.

Target is the range that changes and triggers the worksheet_change event. This is determined automatically by Excel. For example, if you enter "Hello" in cell A1, the Worksheet_Change event will trigger, and Target will be Range("A1").

If you copy A1 to B2:B4, then the Worksheet_Change event will trigger again, and Target will be Range("B2:B4").
 
Upvote 0

Forum statistics

Threads
1,216,084
Messages
6,128,722
Members
449,465
Latest member
TAKLAM

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