[02/03] How to convert Windows system color into its RGB value

T

thomasc

Hello,

This is about VB.NET2003.

I'm trying to obtain the RGB value of a Windows system color and use
it as the background color of my Microsoft Word file. But I have not
been able to find out how I can do so.

THe name of the system color I'm interested in is
"System.Drawing.SystemColors.Control".

Please let me know how I can obtain RGB value of a Windows system
color.


Thanks much in advance!
 
H

Herfried K. Wagner [MVP]

thomasc said:
I'm trying to obtain the RGB value of a Windows system color and use
it as the background color of my Microsoft Word file. But I have not
been able to find out how I can do so.

THe name of the system color I'm interested in is
"System.Drawing.SystemColors.Control".

Please let me know how I can obtain RGB value of a Windows system
color.

Take a look at 'Color.ToArgb'. 'SystemColors.Control' is a value of type
'Color'.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top