Jump to content
Xtreme .Net Talk

Recommended Posts

Posted (edited)

Nevermind. You just save it as a number. All I need is how to get the integer equivalenes of these color values:

 

fff9fbdd

ffe7e8d0

ffbfe0f2

ffe7e8d0

ffd5e2ec

Edited by aewarnick
C#
Posted

Nevermind, the integer equivalent is too big.

And even when I put it in my code like this:

 

CommunicationLog.RegColors.SetValue("LogBoxColor", 0xffeeecd7);

 

It still saves as a string and not a dword. I am stumped.

C#
Posted

These are both red

 

CommunicationLog.RegColors.SetValue("LogBoxColor", 0xffff0000);

//TBLabelsColor

CommunicationLog.RegColors.SetValue("TBLabelsColor", -65536);

 

but the top is the one seen in the registry and it does not work in the code. I don't see any way to get that bottom number for unknown colors (unlike red).

 

I don't see how those 2 numbers are alike because in the registry it says that 0xffff0000 is 4294901760 and not -65536.

 

Can someone help?

 

By the way, I am using the FromArgb methods to get the colors.

C#

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...