为什么CDialogBar显示后,按钮是灰色的?

BEGIN_MESSAGE_MAP(CLeftDlgBar, CDialogBar)
ON_UPDATE_COMMAND_UI(IDC_BUTTON1,OnUpdateButton1)
END_MESSAGE_MAP()
void CLeftDlgBar::OnUpdateButton1(CCmdUI* pCmdUI)
{
pCmdUI->Enable(TRUE);
//using pCmdUI->SetText you can set the button text too
}

Leave a Reply

Your email address will not be published. Required fields are marked *