Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
need codeto view the 56 colors of ColorIndex
Help with this please I trying to write for a buton the will change a cell color each press will increment the ColorIndex property. Also a question ...does the ColorIndex # relate directly to the colo pallet used when changing a cell color manually? They dont seem to correspond. Thank you for the hel -- SuitedAce ----------------------------------------------------------------------- SuitedAces's Profile: http://www.excelforum.com/member.php...fo&userid=3584 View this thread: http://www.excelforum.com/showthread.php?threadid=55718 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
need codeto view the 56 colors of ColorIndex
Hello SuitedAces, The pallet is arranged by color not by color index values. Here is a macro that will change the active cell's background color according to the color index sequentially. It places the color index in the cell to the right. You can comment this line out if you like. Code: -------------------- Sub ChangeColor() Dim N As Integer Static CI As Integer CI = CI + 1 With ActiveCell N = CI Mod 57 .Interior.ColorIndex = N .Offset(0, 1).Value = N End With End Sub -------------------- Sincerely, Leith Ross -- Leith Ross ------------------------------------------------------------------------ Leith Ross's Profile: http://www.excelforum.com/member.php...o&userid=18465 View this thread: http://www.excelforum.com/showthread...hreadid=557183 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
need codeto view the 56 colors of ColorIndex
Thank you very much. I am a beginner and struggling with using variables for looping and trying to figure out where I need to declare the variables. This will help clue me in -- SuitedAce ----------------------------------------------------------------------- SuitedAces's Profile: http://www.excelforum.com/member.php...fo&userid=3584 View this thread: http://www.excelforum.com/showthread.php?threadid=55718 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Workbook View / Appearance - Colors | Excel Discussion (Misc queries) | |||
Why can I only view colors in Excel when I print preview? | Excel Discussion (Misc queries) | |||
view colors in open worksheet | Excel Discussion (Misc queries) | |||
What are the values for ColorIndex 's 56 colors ? i.e. green=3 . | Excel Programming | |||
WHere can I find a list of ColorIndex colors? | Excel Programming |