RGB lookup

chef

Well-known Member
Joined
Jul 10, 2002
Messages
610
Office Version
  1. 365
  2. 2016
I am wondering if there is an easy way to create a colour pallette using lookup to automatically display the RGB colour/shade

I have 3 columns in B,C & D and eg 138 in B1, 127 in C1 and 128 in D1 and in column E, I change the colour manually with the codes to see what shade that is ie grey

Is there a way I can type in various RGB codes in the column rows and have the colours and shades fill in each row in column D

many thanks
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.
You can do that with a macro like
VBA Code:
Sub chef()
   Dim Cl As Range
   
   For Each Cl In Range("E2:E" & Range("D" & Rows.count).End(xlUp).Row)
      Cl.Interior.Color = RGB(Cl.Offset(, -3), Cl.Offset(, -2), Cl.Offset(, 1))
   Next Cl
End Sub
 
Upvote 0
wow...that worked a treat and genius.....thats so helpful and thanks for taking the time to do that as well appreciated.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,215,575
Messages
6,125,632
Members
449,241
Latest member
NoniJ

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