
Change background color of selected text
Hi Rene,
You can use SetSelectionCharFormat to change the selected text:
CHARFORMAT cf;
cf.dwMask = CFM_COLOR;
cf.dwEffects =0;
cf.crTextColor=RGB(255,0,0);
m_MyRichEdit.SetSelectionCharFormat(cf);
I hope this helps. If you have additional questions on this topic, please
reply to this posting.
Need quick answers to questions like these? The Microsoft Knowledge Base
provides a wealth of information that you can use to troubleshoot a problem
or answer a question! It's located at
http://support.microsoft.com/support/c.asp?M=F>.
This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. Copy Right, 2001 Microsoft Corporation.
All rights reserved.
Regards,
Felix Wu