PC Review


Reply
 
 
JAD
Guest
Posts: n/a
 
      6th Sep 2008
Can anyone point me to a source that will give me all the colors available
with code that I can use for the fore and background colors in a Toggle
Button? Also, instead of entering a color in VB such as vbBlack, can you also
defined the color by entering numbers? Any help would be appreciated. Thank
You, JAD
 
Reply With Quote
 
 
 
 
Gary Keramidas
Guest
Posts: n/a
 
      6th Sep 2008
maybe this will help


Sub Colors()
Dim ctr As Long

For ctr = 1 To 56
Cells(ctr, 1).Interior.ColorIndex = ctr
Cells(ctr, 2).Value = "'" & Right("000000" & _
Hex(ThisWorkbook.Colors(ctr)), 6)
Cells(ctr, 3).Value = ctr
Cells(ctr, 4).Value = Cells(ctr, 1).Interior.Color
Cells(ctr, 2).Font.Name = "Arial"
Cells(ctr, 2).HorizontalAlignment = xlRight
Cells(ctr, 3).HorizontalAlignment = xlCenter
Cells(ctr, 4).HorizontalAlignment = xlLeft
Next ctr

End Sub

--


Gary


"JAD" <(E-Mail Removed)> wrote in message
news:821C9761-4E00-41C4-837F-(E-Mail Removed)...
> Can anyone point me to a source that will give me all the colors available
> with code that I can use for the fore and background colors in a Toggle
> Button? Also, instead of entering a color in VB such as vbBlack, can you also
> defined the color by entering numbers? Any help would be appreciated. Thank
> You, JAD



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Numbered list- want to color just one word with color, not number Jugglertwo Microsoft Word Document Management 12 3rd Apr 2010 01:49 PM
validation list color nbarr Microsoft Excel Misc 1 5th Feb 2009 11:48 PM
Color List? =?Utf-8?B?RGFuIHRoZSBNYW4=?= Microsoft Excel Programming 7 19th Aug 2007 01:32 PM
Keep Color In List =?Utf-8?B?U2Vhbg==?= Microsoft Excel Misc 0 21st Mar 2007 08:18 PM
List Box and different color Alessandro Microsoft ASP .NET 1 4th Jul 2003 03:05 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:15 PM.