|
-
Aug 23rd, 2008, 10:31 AM
#1
Thread Starter
Fanatic Member
Color Chart or Table for color codes
Can someone point me at a location of where I could find a chart showing which colors match which color codes that are used by VB?
&H00000000& = Black.
Preferably the chart has a few more colors than the 48 colors in the color palette.
-
Aug 23rd, 2008, 11:13 AM
#2
Re: Color Chart or Table for color codes
Open up your Object Browser in the VB IDE (Press F2) and search for vbBlack. The constants will all be listed out with their hex color codes but constant values are easier to work with.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Aug 23rd, 2008, 11:18 AM
#3
Re: Color Chart or Table for color codes
If you are familiar with RGB values, and can convert the 0-255 decimal values into two-character hex values, then this may be helpful:
&H00BBGGRR&
-
Aug 23rd, 2008, 11:22 AM
#4
Re: Color Chart or Table for color codes
Although thats true, why would you want to do all that extra work for determining the standard and system colors?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Aug 23rd, 2008, 11:29 AM
#5
Re: Color Chart or Table for color codes
This sample project might be helpful to you.
-
Aug 23rd, 2008, 12:29 PM
#6
Thread Starter
Fanatic Member
Re: Color Chart or Table for color codes
Was hoping there would be a simple chart where I could look for the colour I was after and copy the colour code. The standard color palette doesn't really contain the colours I want.
I can't seem to find anything on the net which I find strange.
This:
color = RGB(255,255,0) '(r, g, b)
from the sample project does the trick for me. I just need to work out what rgb's combinations I need.
Logophobic, your's is an alternative but the above does the trick.
Thanks all!
-
Aug 23rd, 2008, 12:34 PM
#7
Re: Color Chart or Table for color codes
Unless you completely control the canvas you don't want to mess around with colors.
I've seen lots of programs where somebody got "cute" with colors that looked good on his tricked out, "window-blinded" machine and were completely unreadable on a standard machine, or on XP themed machines, or when somebody chose a non-default Windows color scheme.
-
Aug 23rd, 2008, 12:41 PM
#8
Re: Color Chart or Table for color codes
Yea, like with the Janus Explorer control it uses custom colouring to achieve the XP theme color but when run under Vista its all greyed out and sickly looking. They should have had it extract and link to the resource file of the theme in use etc. But thats just my opinion.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Aug 24th, 2008, 04:29 PM
#9
Re: Color Chart or Table for color codes
here is the basic values for rgb,
Code:
Color Red Value Green Value Blue Value
Black 0 0 0
Blue 0 0 255
Green 0 255 0
Cyan 0 255 255
Red 255 0 0
Magenta 255 0 255
Yellow 255 255 0
White 255 255 255
i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next
dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part
come back and mark your original post as resolved if your problem is fixed
pete
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|