Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS Tech Support » GetColor in CExtGridCellColor returns wrong RGB Collapse All
Subject Author Date
Eric Houvenaghel Feb 10, 2009 - 10:49 AM

I call GetColor when the user selects a colour.


The following COLORREF should be:


Red: 0x00FF0000


Green: 0x0000FF00


Blue: 0x000000FF


What you get form GetColor is the following:


Red: 0x000000FF


Green: 0x0000FF00


Blue: 0x00FF0000


The red and blue seem to be reversed.


Please confirm if this is a bug or misuse on my part.


Thanks.

Technical Support Feb 11, 2009 - 8:39 AM

Prof-UIS uses the RGB(), GetRValue(), GetGValue() and GetBValue() preprocessor functions from Win32 API for working with COLORREF variables. We also have our own __EXT_MFC_RGBA and GetAValue() preprocessor functions but they does not conflict with Win32 preprocessor functions. So, the colors should not be mismatched. You should not have any problems with colors if you are using the same Win32 preprocessor functions. At least, you are the first person suspecting this issue when the color grid cell is enough old.