Click here to Skip to main content
11,922,641 members (56,183 online)
Click here to Skip to main content
Add your own
alternative version


4 bookmarked

System Color Viewer

, 30 Jan 2013 CPOL
Rate this:
Please Sign up or sign in to vote.
View each color in System.Drawing.Color


When I make GDI+ projects, I need color information, and I used the 'DevColor' extension before, it is a very good one but it doesn't work on my machine now (VS2012). So today, I created this viewer for a simple way to access color information in the System.Drawing.Color class.

Using the Code

Here is the code:

private void updateView()

    object obj= Color.AliceBlue ;

    PropertyInfo[] ps = typeof(Color).GetProperties();

    for (int i = 0; i < ps.Length; i++)
        if (ps[i].DeclaringType == typeof(Color)) 
            obj = ps[i].GetValue(new Color(), null);
            if (obj is Color)
                listView1.Items.Add(new ListViewItem(new string[] { 


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Software Developer CONSPEC CONTROLS
China China
Happy to meet you!

You may also be interested in...

Comments and Discussions

QuestionAn extended version of your "System Color Viewer" … Pin
Martin08154-Feb-13 2:33
memberMartin08154-Feb-13 2:33 
AnswerRe: An extended version of your "System Color Viewer" … Pin
Chen.shaohua9-Feb-13 21:05
memberChen.shaohua9-Feb-13 21:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.151125.1 | Last Updated 30 Jan 2013
Article Copyright 2013 by Chen.shaohua
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid