RGB color code / MS Access color code equivalent

StanLeakup

New member
Local time
Today, 11:28
Joined
Oct 2, 2018
Messages
4
Hi,

I have a set of colors and their RGB values that I am trying to get the color code equivalent for in MS Access code. The following colors and their RGB values are listed below:

Dark Blue: 79, 129, 189
Light Blue: 220, 230, 241

I am trying to get the color code equivalent in MS Access. How would I do this?

Thank you.
 
You can use...

RGB (79, 129, 189) and RGB (220, 230, 241) in code...

...or just go to the control. Select More under colors and set the RGB code in and it will give you the numeric value.
 
I don't have the MS Access app unfortunately. Would you mind sending me the 8 code equivalent for those two colors if you have a chance? Thank you.
 
Hmm, okay well not sure what you mean by 8 code equivalent, unless... are in you Access 2003? That said, which 8 code equivalent, there are several and they are not all 8 code.

For Access 2010 and above.
Dark Blue : #4F81BD of which the octal value is 23700675 but the numeric value 5210557
Light Blue: #DCE6F1 of which the octal value is 7226504 but numeric value is 1912132
 
RGB to MS Access.PNG

Thanks for your reply. I have attached a screenshot of the two colors I need the MS Access values for vs. the octal codes you have provided. The colors do not appear to match. I am using the VBA editor in excel and it is asking me for the MS Access value instead of the RGB value to get the appropriate colors.
 
Hi Stan
See attached for my colour converter utility which gives you the Access OLE Colour, RGB & HEX values.
Enter the RGB values manually or use the slider(s) to get the desired colour

As the utility is an access app which you say isn't available to you, the screenshots shows the values you wanted

Dark blue
attachment.php


Light blue (?) - looks grey to me!
attachment.php


NOTE: The latest version of my app s available at:
 

Attachments

  • ColourConverter.zip
    ColourConverter.zip
    55.6 KB · Views: 667
  • ColourConverter1.PNG
    ColourConverter1.PNG
    13.7 KB · Views: 5,641
  • ColourConverter2.PNG
    ColourConverter2.PNG
    13.9 KB · Views: 5,208
Last edited:
If you want the colour code value, try highlighting the coloured cell and then in your Immediate Window type the following:

Code:
? Selection.Interior.Color
 
Thanks Colin, I completely forgot about OLE colors been a long time. And cool tool!
 
Hi Stan
See attached for my colour converter utility which gives you the Access OLE Colour, RGB & HEX values.
Enter the RGB values manually or use the slider(s) to get the desired colour

As the utility is an access app which you say isn't available to you, the screenshots shows the values you wanted

Dark blue
attachment.php


Light blue (?) - looks grey to me!
attachment.php


NOTE: The latest version of my app s available at:
Thank you very much isladogs
I was looking for it for the purpose of coloring the datasheet.
 
I am using the VBA editor in excel

Excel DOES have an RGB function BUT... for Excel's RGB function, the red and blue colors are reversed in order. Green is still in the middle. (That tripped me up the first time I ran into that.)

RGB (79, 129, 189) and RGB (220, 230, 241)

Use Excel's RGB as RGB( 189, 129, 79 ) or RGB( 241, 230, 220 )
 
I came across this site the other day that some may also find helpful. www.html-color.codes
Just about any colour you will need is shown in a way that gives a helpful comparison if you are looking for just shades different.
(well I thought it did)
 
You can also open (copy paste) the image into paint and use the eye dropper tool to select the color and then Edit the colors.
1727099631849.png
 
I forget which way round it is offhand, but the colour value is effectively

Rx256^2+Gx256+B

The RGB values might be evaluated the other way round.

When R,G and B are values in the range 0 to 255
 
I never used to manipulate colors using decimal OR octal. They are best expressed in HEXADECIMAL where your codes can immediately tell you what color you are looking at because they fall into columns within the number.

0x00FF0000 = strongest red = RGB(255,0,0)
0x0000FF00 = strongest green = RGB(0,255,0)
0x000000FF = strongest blue = RGB( 0,0, 255)
0x00808080 = mid-gray = RFB(128, 128, 128)
0x00rrggbb = the locations for the colors in hex.

When you have these colors in HEX, it is easy to see if a particular color predominates.
 

Users who are viewing this thread

Back
Top Bottom