Click here to Skip to main content
15,906,341 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Questiondatabase connectivity Pin
yogesh_softworld1235-May-08 22:49
yogesh_softworld1235-May-08 22:49 
QuestionRe: database connectivity Pin
Rajesh R Subramanian5-May-08 22:51
professionalRajesh R Subramanian5-May-08 22:51 
AnswerRe: database connectivity Pin
toxcct5-May-08 22:58
toxcct5-May-08 22:58 
AnswerRe: database connectivity Pin
CPallini5-May-08 23:33
mveCPallini5-May-08 23:33 
AnswerRe: database connectivity Pin
Hamid_RT6-May-08 1:20
Hamid_RT6-May-08 1:20 
Questionchild control flickers [modified] Pin
followait5-May-08 22:47
followait5-May-08 22:47 
AnswerRe: child control flicks Pin
Nelek6-May-08 1:55
protectorNelek6-May-08 1:55 
GeneralRe: child control flicks Pin
followait6-May-08 3:40
followait6-May-08 3:40 
The OnDraw function is left default.
The OnErase is as below:

BOOL CMyEditorDlg::OnEraseBkgnd( CDC* pDC )
{
	CRect rcClient;
	GetClientRect(&rcClient);

	Graphics g(pDC->m_hDC);

	//////////////////////////////////////////////////////////////////////////
	//cap
	CRect rc(rcClient);
	rc.bottom=rc.top+m_capH;
	Bitmap bmBkCap(rc.Width(),rc.Height(),PixelFormat32bppARGB);
	Graphics gMemBkCap(&bmBkCap);
	TextureBrush brBkCap(&m_bmCapBkM);
	gMemBkCap.FillRectangle(&brBkCap,m_bmCapBkL.GetWidth(),0,
		rc.Width()-m_bmCapBkL.GetWidth()-m_bmCapBkR.GetWidth(),m_bmCapBkM.GetHeight());
	gMemBkCap.DrawImage(&m_bmCapBkL,0,0);
	gMemBkCap.DrawImage(&m_bmCapBkR,rc.right-m_bmCapBkR.GetWidth(),0);
	gMemBkCap.DrawImage(&m_bmCapBkTitle,(rc.Width()-m_bmCapBkTitle.GetWidth())/2,0);

	//////////////////////////////////////////////////////////////////////////
	//tool area bg
	rc=rcClient;
	rc.top=rc.bottom-m_footH;
	Bitmap bmBkFoot(rc.Width(),rc.Height(),PixelFormat32bppARGB);
	Graphics gMemBkFoot(&bmBkFoot);
	TextureBrush brBkFoot(&m_bmFootBkM);
	gMemBkFoot.FillRectangle(&brBkFoot,m_bmFootBkL.GetWidth(),0,
		rc.Width()-m_bmFootBkL.GetWidth()-m_bmFootBkR.GetWidth(),m_bmFootBkM.GetHeight());
	gMemBkFoot.DrawImage(&m_bmFootBkL,0,0);
	gMemBkFoot.DrawImage(&m_bmFootBkR,rc.right-m_bmFootBkR.GetWidth(),0);

	//////////////////////////////////////////////////////////////////////////
	//
	g.Clear((ARGB)Color::White);
	g.DrawImage(&bmBkCap,0,0);
	g.DrawImage(&bmBkFoot,0,rc.top);

	return TRUE;
}

GeneralRe: child control flicks Pin
Rajkumar R6-May-08 4:46
Rajkumar R6-May-08 4:46 
GeneralRe: child control flicks Pin
followait6-May-08 13:09
followait6-May-08 13:09 
GeneralRe: child control flicks Pin
followait6-May-08 13:56
followait6-May-08 13:56 
GeneralRe: child control flicks Pin
Rajkumar R6-May-08 23:56
Rajkumar R6-May-08 23:56 
QuestionDoModal() Dialog Position Pin
mehmetned5-May-08 22:19
mehmetned5-May-08 22:19 
AnswerRe: DoModal() Dialog Position Pin
Cedric Moonen5-May-08 22:23
Cedric Moonen5-May-08 22:23 
AnswerRe: DoModal() Dialog Position Pin
Nibu babu thomas5-May-08 22:39
Nibu babu thomas5-May-08 22:39 
AnswerRe: DoModal() Dialog Position Pin
wct27-Mar-11 21:00
wct27-Mar-11 21:00 
QuestionHow to find component properties when i hold the object hWnd ? Pin
Yanshof5-May-08 22:09
Yanshof5-May-08 22:09 
AnswerRe: How to find component properties when i hold the object hWnd ? Pin
spsharma6-May-08 0:01
spsharma6-May-08 0:01 
GeneralRe: How to find component properties when i hold the object hWnd ? Pin
Yanshof6-May-08 0:45
Yanshof6-May-08 0:45 
GeneralRe: How to find component properties when i hold the object hWnd ? Pin
Rajkumar R6-May-08 2:40
Rajkumar R6-May-08 2:40 
QuestionProblems with string as member variable Pin
piul5-May-08 22:05
piul5-May-08 22:05 
AnswerRe: Problems with string as member variable Pin
Cedric Moonen5-May-08 22:13
Cedric Moonen5-May-08 22:13 
QuestionRe: Problems with string as member variable Pin
CPallini5-May-08 22:15
mveCPallini5-May-08 22:15 
AnswerRe: Problems with string as member variable Pin
piul5-May-08 22:31
piul5-May-08 22:31 
GeneralRe: Problems with string as member variable Pin
CPallini5-May-08 22:40
mveCPallini5-May-08 22:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.