同样一段代码,我放在按钮里面好使,但放在初始化函数或用初始化函数调用按钮都不行。这是为什么呢?
函数为绘制图片,主要代码如下:
UpdateData(TRUE);
CRect rc;
CDC* pDC = m_Picture_Dlg.GetDC();
m_Picture_Dlg.GetClientRect(&rc);
pDC->SetViewportOrg(0, rc.bottom);
rc.bottom = -rc.bottom;
if (!picture)
{
picture = new CPicture;
}
picture->Load(tmp1);
picture->Render(pDC, &rc, NULL);
对VC不太懂啊,求帮忙啊!!!!
函数为绘制图片,主要代码如下:
UpdateData(TRUE);
CRect rc;
CDC* pDC = m_Picture_Dlg.GetDC();
m_Picture_Dlg.GetClientRect(&rc);
pDC->SetViewportOrg(0, rc.bottom);
rc.bottom = -rc.bottom;
if (!picture)
{
picture = new CPicture;
}
picture->Load(tmp1);
picture->Render(pDC, &rc, NULL);
对VC不太懂啊,求帮忙啊!!!!
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货