+ Reply to Thread
Results 1 to 9 of 9

how to get lighter shade of gray for interior color of a cell?

  1. #1
    Rich
    Guest

    how to get lighter shade of gray for interior color of a cell?

    Hello,

    I recorded a macro for setting the interior color of a cell to the lightest
    gray in the color palet on the toolbar. But I need a lighter shade of gray.
    I experimented with various color indexes, but these indexes seem to only use
    the colors from the color palet on the toolbar. Is there a way to use the
    RGB color function maybe, to color the interior of a cell to a shade that is
    not on the color palet on the toolbar? How is this done?

    Thanks,
    Rich

  2. #2
    Jim Thomlinson
    Guest

    RE: how to get lighter shade of gray for interior color of a cell?

    Additionally here is a recent post from Chip...

    Note that Excel supports only 56 colors, although you can specify
    which 56 colors are used. If you attempt to use a color that is
    not in Excel's palette of colors, Excel will use the closest
    match. To use a specific color with RGB, you should set one of
    the colors in the palette to that color, then use ColorIndex to
    get the color to the cell. E.g,

    ThisWorkbook.Colors(56) = RGB(r,g,b)
    ActiveCell.Interior.ColorIndex = 56

    See www.cpearson.com/excel/colors.htm for more info about working
    with colors.


    --
    HTH...

    Jim Thomlinson


    "Rich" wrote:

    > Hello,
    >
    > I recorded a macro for setting the interior color of a cell to the lightest
    > gray in the color palet on the toolbar. But I need a lighter shade of gray.
    > I experimented with various color indexes, but these indexes seem to only use
    > the colors from the color palet on the toolbar. Is there a way to use the
    > RGB color function maybe, to color the interior of a cell to a shade that is
    > not on the color palet on the toolbar? How is this done?
    >
    > Thanks,
    > Rich


  3. #3
    Jim Thomlinson
    Guest

    RE: how to get lighter shade of gray for interior color of a cell?

    Take a look at this...

    http://www.cpearson.com/excel/colors.htm#RGB
    --
    HTH...

    Jim Thomlinson


    "Rich" wrote:

    > Hello,
    >
    > I recorded a macro for setting the interior color of a cell to the lightest
    > gray in the color palet on the toolbar. But I need a lighter shade of gray.
    > I experimented with various color indexes, but these indexes seem to only use
    > the colors from the color palet on the toolbar. Is there a way to use the
    > RGB color function maybe, to color the interior of a cell to a shade that is
    > not on the color palet on the toolbar? How is this done?
    >
    > Thanks,
    > Rich


  4. #4
    Rich
    Guest

    RE: how to get lighter shade of gray for interior color of a cell?

    Thank you very much for your reply. One more question if I may - is there a
    way to determine what color you get with RGB ? like what numbers to select?
    I have always had a problem with that using RGB. Is there maybe website that
    lists that various color you can get with RBG?

    Also, I did notice that the lightest color of gray that I was able to get
    using RGB (but not adding to the palette yet) was the same shade that is
    currently in the palette. So if I find an RGB number that is lighter, and I
    add that to the palette in my respective workbook, then I can use that color?

    Thanks again.

    "Jim Thomlinson" wrote:

    > Additionally here is a recent post from Chip...
    >
    > Note that Excel supports only 56 colors, although you can specify
    > which 56 colors are used. If you attempt to use a color that is
    > not in Excel's palette of colors, Excel will use the closest
    > match. To use a specific color with RGB, you should set one of
    > the colors in the palette to that color, then use ColorIndex to
    > get the color to the cell. E.g,
    >
    > ThisWorkbook.Colors(56) = RGB(r,g,b)
    > ActiveCell.Interior.ColorIndex = 56
    >
    > See www.cpearson.com/excel/colors.htm for more info about working
    > with colors.
    >
    >
    > --
    > HTH...
    >
    > Jim Thomlinson
    >
    >
    > "Rich" wrote:
    >
    > > Hello,
    > >
    > > I recorded a macro for setting the interior color of a cell to the lightest
    > > gray in the color palet on the toolbar. But I need a lighter shade of gray.
    > > I experimented with various color indexes, but these indexes seem to only use
    > > the colors from the color palet on the toolbar. Is there a way to use the
    > > RGB color function maybe, to color the interior of a cell to a shade that is
    > > not on the color palet on the toolbar? How is this done?
    > >
    > > Thanks,
    > > Rich


  5. #5
    Peter T
    Guest

    Re: how to get lighter shade of gray for interior color of a cell?

    If you want a grey just make all the RGB colours the same.

    FYI, the lightest gray in a default palette is applied to colorindex 15 as
    RGB(192,192,192)

    You might try, say

    Activeworkbook.colors(54) = rgb(204,204,204)
    Activeworkbook.colors(39) = rgb(229,229,229)

    Each RGB attribute should be in the range 0-255

    As there are 256 x 256 x 256 = 16 million permutations, no web site will
    show you all possible RGB colours. Though plenty of sites display the so
    called "web safe" colours that exist in the old 256 colour palette.

    Regards,
    Peter T

    "Rich" <[email protected]> wrote in message
    news:[email protected]...
    > Thank you very much for your reply. One more question if I may - is there

    a
    > way to determine what color you get with RGB ? like what numbers to

    select?
    > I have always had a problem with that using RGB. Is there maybe website

    that
    > lists that various color you can get with RBG?
    >
    > Also, I did notice that the lightest color of gray that I was able to get
    > using RGB (but not adding to the palette yet) was the same shade that is
    > currently in the palette. So if I find an RGB number that is lighter, and

    I
    > add that to the palette in my respective workbook, then I can use that

    color?
    >
    > Thanks again.
    >
    > "Jim Thomlinson" wrote:
    >
    > > Additionally here is a recent post from Chip...
    > >
    > > Note that Excel supports only 56 colors, although you can specify
    > > which 56 colors are used. If you attempt to use a color that is
    > > not in Excel's palette of colors, Excel will use the closest
    > > match. To use a specific color with RGB, you should set one of
    > > the colors in the palette to that color, then use ColorIndex to
    > > get the color to the cell. E.g,
    > >
    > > ThisWorkbook.Colors(56) = RGB(r,g,b)
    > > ActiveCell.Interior.ColorIndex = 56
    > >
    > > See www.cpearson.com/excel/colors.htm for more info about working
    > > with colors.
    > >
    > >
    > > --
    > > HTH...
    > >
    > > Jim Thomlinson
    > >
    > >
    > > "Rich" wrote:
    > >
    > > > Hello,
    > > >
    > > > I recorded a macro for setting the interior color of a cell to the

    lightest
    > > > gray in the color palet on the toolbar. But I need a lighter shade of

    gray.
    > > > I experimented with various color indexes, but these indexes seem to

    only use
    > > > the colors from the color palet on the toolbar. Is there a way to use

    the
    > > > RGB color function maybe, to color the interior of a cell to a shade

    that is
    > > > not on the color palet on the toolbar? How is this done?
    > > >
    > > > Thanks,
    > > > Rich




  6. #6
    Jim Thomlinson
    Guest

    RE: how to get lighter shade of gray for interior color of a cell?

    As for the colors generated by RGB the number is astronomical (16 Million
    256*256*256) so you may not have a lot of luck finding a website that shows
    all of the colours...

    As I understand it once you add the color to the pallet you can feel free to
    use it. The only caveat is that you can only have 56 colors in total.
    --
    HTH...

    Jim Thomlinson


    "Rich" wrote:

    > Thank you very much for your reply. One more question if I may - is there a
    > way to determine what color you get with RGB ? like what numbers to select?
    > I have always had a problem with that using RGB. Is there maybe website that
    > lists that various color you can get with RBG?
    >
    > Also, I did notice that the lightest color of gray that I was able to get
    > using RGB (but not adding to the palette yet) was the same shade that is
    > currently in the palette. So if I find an RGB number that is lighter, and I
    > add that to the palette in my respective workbook, then I can use that color?
    >
    > Thanks again.
    >
    > "Jim Thomlinson" wrote:
    >
    > > Additionally here is a recent post from Chip...
    > >
    > > Note that Excel supports only 56 colors, although you can specify
    > > which 56 colors are used. If you attempt to use a color that is
    > > not in Excel's palette of colors, Excel will use the closest
    > > match. To use a specific color with RGB, you should set one of
    > > the colors in the palette to that color, then use ColorIndex to
    > > get the color to the cell. E.g,
    > >
    > > ThisWorkbook.Colors(56) = RGB(r,g,b)
    > > ActiveCell.Interior.ColorIndex = 56
    > >
    > > See www.cpearson.com/excel/colors.htm for more info about working
    > > with colors.
    > >
    > >
    > > --
    > > HTH...
    > >
    > > Jim Thomlinson
    > >
    > >
    > > "Rich" wrote:
    > >
    > > > Hello,
    > > >
    > > > I recorded a macro for setting the interior color of a cell to the lightest
    > > > gray in the color palet on the toolbar. But I need a lighter shade of gray.
    > > > I experimented with various color indexes, but these indexes seem to only use
    > > > the colors from the color palet on the toolbar. Is there a way to use the
    > > > RGB color function maybe, to color the interior of a cell to a shade that is
    > > > not on the color palet on the toolbar? How is this done?
    > > >
    > > > Thanks,
    > > > Rich


  7. #7
    Peter T
    Guest

    Re: how to get lighter shade of gray for interior color of a cell?

    PS, forgot I posted a macro to display the 216 "web-safe" colours in a
    worksheet here

    http://tinyurl.com/fay37

    Other colours in the old 256 palette are greys and system colours.

    Regards,
    Peter T


    "Peter T" <peter_t@discussions> wrote in message
    news:[email protected]...
    > If you want a grey just make all the RGB colours the same.
    >
    > FYI, the lightest gray in a default palette is applied to colorindex 15 as
    > RGB(192,192,192)
    >
    > You might try, say
    >
    > Activeworkbook.colors(54) = rgb(204,204,204)
    > Activeworkbook.colors(39) = rgb(229,229,229)
    >
    > Each RGB attribute should be in the range 0-255
    >
    > As there are 256 x 256 x 256 = 16 million permutations, no web site will
    > show you all possible RGB colours. Though plenty of sites display the so
    > called "web safe" colours that exist in the old 256 colour palette.
    >
    > Regards,
    > Peter T
    >
    > "Rich" <[email protected]> wrote in message
    > news:[email protected]...
    > > Thank you very much for your reply. One more question if I may - is

    there
    > a
    > > way to determine what color you get with RGB ? like what numbers to

    > select?
    > > I have always had a problem with that using RGB. Is there maybe website

    > that
    > > lists that various color you can get with RBG?
    > >
    > > Also, I did notice that the lightest color of gray that I was able to

    get
    > > using RGB (but not adding to the palette yet) was the same shade that is
    > > currently in the palette. So if I find an RGB number that is lighter,

    and
    > I
    > > add that to the palette in my respective workbook, then I can use that

    > color?
    > >
    > > Thanks again.
    > >
    > > "Jim Thomlinson" wrote:
    > >
    > > > Additionally here is a recent post from Chip...
    > > >
    > > > Note that Excel supports only 56 colors, although you can specify
    > > > which 56 colors are used. If you attempt to use a color that is
    > > > not in Excel's palette of colors, Excel will use the closest
    > > > match. To use a specific color with RGB, you should set one of
    > > > the colors in the palette to that color, then use ColorIndex to
    > > > get the color to the cell. E.g,
    > > >
    > > > ThisWorkbook.Colors(56) = RGB(r,g,b)
    > > > ActiveCell.Interior.ColorIndex = 56
    > > >
    > > > See www.cpearson.com/excel/colors.htm for more info about working
    > > > with colors.
    > > >
    > > >
    > > > --
    > > > HTH...
    > > >
    > > > Jim Thomlinson
    > > >
    > > >
    > > > "Rich" wrote:
    > > >
    > > > > Hello,
    > > > >
    > > > > I recorded a macro for setting the interior color of a cell to the

    > lightest
    > > > > gray in the color palet on the toolbar. But I need a lighter shade

    of
    > gray.
    > > > > I experimented with various color indexes, but these indexes seem to

    > only use
    > > > > the colors from the color palet on the toolbar. Is there a way to

    use
    > the
    > > > > RGB color function maybe, to color the interior of a cell to a shade

    > that is
    > > > > not on the color palet on the toolbar? How is this done?
    > > > >
    > > > > Thanks,
    > > > > Rich

    >
    >




  8. #8
    Rich
    Guest

    RE: how to get lighter shade of gray for interior color of a cell?

    Thank you all for your replies. Now I get it - only 56 color in the color
    palette. I added

    ActiveWorkbook.Colors(39) = RGB(229, 229, 229)

    that is the shade of gray that I needed.

    "Rich" wrote:

    > Thank you very much for your reply. One more question if I may - is there a
    > way to determine what color you get with RGB ? like what numbers to select?
    > I have always had a problem with that using RGB. Is there maybe website that
    > lists that various color you can get with RBG?
    >
    > Also, I did notice that the lightest color of gray that I was able to get
    > using RGB (but not adding to the palette yet) was the same shade that is
    > currently in the palette. So if I find an RGB number that is lighter, and I
    > add that to the palette in my respective workbook, then I can use that color?
    >
    > Thanks again.
    >
    > "Jim Thomlinson" wrote:
    >
    > > Additionally here is a recent post from Chip...
    > >
    > > Note that Excel supports only 56 colors, although you can specify
    > > which 56 colors are used. If you attempt to use a color that is
    > > not in Excel's palette of colors, Excel will use the closest
    > > match. To use a specific color with RGB, you should set one of
    > > the colors in the palette to that color, then use ColorIndex to
    > > get the color to the cell. E.g,
    > >
    > > ThisWorkbook.Colors(56) = RGB(r,g,b)
    > > ActiveCell.Interior.ColorIndex = 56
    > >
    > > See www.cpearson.com/excel/colors.htm for more info about working
    > > with colors.
    > >
    > >
    > > --
    > > HTH...
    > >
    > > Jim Thomlinson
    > >
    > >
    > > "Rich" wrote:
    > >
    > > > Hello,
    > > >
    > > > I recorded a macro for setting the interior color of a cell to the lightest
    > > > gray in the color palet on the toolbar. But I need a lighter shade of gray.
    > > > I experimented with various color indexes, but these indexes seem to only use
    > > > the colors from the color palet on the toolbar. Is there a way to use the
    > > > RGB color function maybe, to color the interior of a cell to a shade that is
    > > > not on the color palet on the toolbar? How is this done?
    > > >
    > > > Thanks,
    > > > Rich


  9. #9
    Vic Eldridge
    Guest

    RE: how to get lighter shade of gray for interior color of a cell?

    Another piece of information that may be of interest to you is that the next
    version of Excel (due out this year sometime) will support support 4.3
    billion individual colours. I guess then we'll be able to set the Color
    property to RGB(x,x,x) without the colour reverting back to a colorindex
    value.

    Regards,
    Vic Eldridge


    "Rich" wrote:

    > Thank you all for your replies. Now I get it - only 56 color in the color
    > palette. I added
    >
    > ActiveWorkbook.Colors(39) = RGB(229, 229, 229)
    >
    > that is the shade of gray that I needed.
    >
    > "Rich" wrote:
    >
    > > Thank you very much for your reply. One more question if I may - is there a
    > > way to determine what color you get with RGB ? like what numbers to select?
    > > I have always had a problem with that using RGB. Is there maybe website that
    > > lists that various color you can get with RBG?
    > >
    > > Also, I did notice that the lightest color of gray that I was able to get
    > > using RGB (but not adding to the palette yet) was the same shade that is
    > > currently in the palette. So if I find an RGB number that is lighter, and I
    > > add that to the palette in my respective workbook, then I can use that color?
    > >
    > > Thanks again.
    > >
    > > "Jim Thomlinson" wrote:
    > >
    > > > Additionally here is a recent post from Chip...
    > > >
    > > > Note that Excel supports only 56 colors, although you can specify
    > > > which 56 colors are used. If you attempt to use a color that is
    > > > not in Excel's palette of colors, Excel will use the closest
    > > > match. To use a specific color with RGB, you should set one of
    > > > the colors in the palette to that color, then use ColorIndex to
    > > > get the color to the cell. E.g,
    > > >
    > > > ThisWorkbook.Colors(56) = RGB(r,g,b)
    > > > ActiveCell.Interior.ColorIndex = 56
    > > >
    > > > See www.cpearson.com/excel/colors.htm for more info about working
    > > > with colors.
    > > >
    > > >
    > > > --
    > > > HTH...
    > > >
    > > > Jim Thomlinson
    > > >
    > > >
    > > > "Rich" wrote:
    > > >
    > > > > Hello,
    > > > >
    > > > > I recorded a macro for setting the interior color of a cell to the lightest
    > > > > gray in the color palet on the toolbar. But I need a lighter shade of gray.
    > > > > I experimented with various color indexes, but these indexes seem to only use
    > > > > the colors from the color palet on the toolbar. Is there a way to use the
    > > > > RGB color function maybe, to color the interior of a cell to a shade that is
    > > > > not on the color palet on the toolbar? How is this done?
    > > > >
    > > > > Thanks,
    > > > > Rich


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1