Hi All,
Does anyone know of any way to change the background white color of Edit Box, and color of its text ?
Any idea will be great.
naim1
Printable View
Hi All,
Does anyone know of any way to change the background white color of Edit Box, and color of its text ?
Any idea will be great.
naim1
Yes. Handle the WM_CTLCOLOR and change the colors that you want. There is an example in MSDN on the page for WM_CTLCOLOR (Handling Reflected Messages: An Example of a Reusable control).
Hi,
Handle WM_CTLCOLOR and in your OnCtlColor(CDC* pDC, UINT nCtlColor)
function, use
Oops. Cilu got ahead of me :)Code://set text color
pDC->SetTextColor(RGB(255,255,255));
//set the text's background color
pDC->SetBkColor(RGB(0,0,0));
naim, please don't create multiple threads with the same question