1、添加子对话框的WM_paint消息 代码如下
void CMyQueryDlg::OnPaint()
{
CPaintDC dc(this); // device context for painting
// TODO: Add your message handler code here
CRect rect;
GetClientRect(&rect);
CBrush b(RGB(255,0,0));
dc.FillRect(rect,&b);
// Do not call CDialog::OnPaint() for painting messages
}
可以设定的