//here is my code ,but it doesn't work
CBrush *pBrush;
pBrush = new CBrush(RGB(255,255,255));
// TODO: Change any attributes of the DC here
pDC->SetTextColor(RGB(1, 1, 1));
pDC->SetBkColor(RGB(255,255,255));
return (HBRUSH)(pBrush->GetSafeHandle());
CBrush *pBrush;
pBrush = new CBrush(RGB(255,255,255));
// TODO: Change any attributes of the DC here
pDC->SetTextColor(RGB(1, 1, 1));
pDC->SetBkColor(RGB(255,255,255));
return (HBRUSH)(pBrush->GetSafeHandle());
解决方案 »
- 《Windows程序设计》的一个问题
- 一个关于CHtmlView的问题
- 如何设置字体大小?
- 用VC++如何选取Excel指定的某整行,整列
- 怎么得到光标,试了好些方法都不行,来看看.(最好能把道理说清楚)
- 为什么ActiveX在Debug下正常,Release出错。
- 我是一个中专毕业生,工作两年半了,现在在北京工作,做的是电子产品设计和做软件,月薪6K,我想明年回杭州工作,因为我女朋友在杭州,想
- 请问怎样限定CSplitterWnd的拖动缩放范围?
- 如何给窗体上控件设置Tab键的顺序?
- 小弟的一个让主板扬声器发声的程序,运行不了,神仙指点一下啊
- 'book'转化成int是多少??
- 请问谁能给我聊天程序的原代码,我发誓给他150分以表感谢!
而不是通过自绘
但是我添加的函数好像不起作用?CBrush *pBrush;
pBrush = new CBrush(RGB(255,255,255));
switch (nCtlColor)
{
case CTLCOLOR_BTN :
pDC->SetTextColor(RGB(1, 1, 1));
pDC->SetBkColor(RGB(255,255,255));
return (HBRUSH)(pBrush->GetSafeHandle());
}
return CButton::OnCtlColor(pDC, pWnd, nCtlColor);
应该就可以了。