Click here to Skip to main content
16,016,288 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Question about __FUNCTION__ precompile directive. Pin
George218-Feb-03 2:53
George218-Feb-03 2:53 
GeneralRe: Question about __FUNCTION__ precompile directive. Pin
AlexO18-Feb-03 3:25
AlexO18-Feb-03 3:25 
GeneralRe: Question about __FUNCTION__ precompile directive. Pin
George218-Feb-03 14:53
George218-Feb-03 14:53 
GeneralProblem with Certificates ....cryptography ...plz help Pin
Dimitri Denamany17-Feb-03 23:51
sussDimitri Denamany17-Feb-03 23:51 
Generalformatting output in control box Pin
emrosa17-Feb-03 23:46
emrosa17-Feb-03 23:46 
GeneralRe: formatting output in control box Pin
HENDRIK R18-Feb-03 0:40
HENDRIK R18-Feb-03 0:40 
GeneralRe: formatting output in control box Pin
jhwurmbach18-Feb-03 2:41
jhwurmbach18-Feb-03 2:41 
GeneralCDC & Blitblt Pin
vijayaramaraju17-Feb-03 23:30
vijayaramaraju17-Feb-03 23:30 
Hi,

I've placed this code on the OnInitialUpdate
if(m_pdcMemory->GetSafeHdc() == NULL)
{
CClientDC dc(this);
OnPrepareDC(&dc);

m_pdcMemory->CreateCompatibleDC(&dc);
}

and on the OnPaint handler the following code.

CPaintDC dc(this); // device context for painting

// TODO: Add your message handler code here
OnPrepareDC(&dc);
CRect rectUpdate;
dc.GetClipBox(rectUpdate);

m_pdcMemory->SelectClipRgn(NULL);
m_pdcMemory->IntersectClipRect(&rectUpdate);

CBrush backgroundBrush(::GetSysColor(COLOR_WINDOW));
CBrush* pOldBrush = m_pdcMemory->SelectObject(&backgroundBrush);
m_pdcMemory->PatBlt(rectUpdate.left, rectUpdate.top, rectUpdate.Width(), rectUpdate.Height(),
PATCOPY);

OnDraw(m_pdcMemory);

dc.BitBlt(rectUpdate.left, rectUpdate.top, rectUpdate.Width(), rectUpdate.Height(),
m_pdcMemory, 0, 0, SRCCOPY);

m_pdcMemory->SelectObject(pOldBrush);


In the OnDraw I've included code to draw some stuff. but I'm unable to get any output any idea what the cause could be

GeneralRe: CDC & Blitblt Pin
Pavel Krupets17-Feb-03 23:41
Pavel Krupets17-Feb-03 23:41 
GeneralRe: CDC & Blitblt Pin
vijayaramaraju17-Feb-03 23:48
vijayaramaraju17-Feb-03 23:48 
GeneralRe: CDC & Blitblt Pin
Pavel Krupets18-Feb-03 0:07
Pavel Krupets18-Feb-03 0:07 
GeneralRe: CDC & Blitblt Pin
vijayaramaraju18-Feb-03 0:45
vijayaramaraju18-Feb-03 0:45 
GeneralMulti-threading analysis Pin
Pavel Krupets17-Feb-03 23:23
Pavel Krupets17-Feb-03 23:23 
GeneralRe: Multi-threading analysis Pin
Joan M18-Feb-03 2:57
professionalJoan M18-Feb-03 2:57 
Question"SDI canvas form" from a dialog box ?? Pin
rohit.dhamija17-Feb-03 23:08
rohit.dhamija17-Feb-03 23:08 
AnswerRe: "SDI canvas form" from a dialog box ?? Pin
HENDRIK R17-Feb-03 23:18
HENDRIK R17-Feb-03 23:18 
GeneralMFC 7.0 Print Preview bug Pin
Anonymous17-Feb-03 22:38
Anonymous17-Feb-03 22:38 
GeneralDialog box before SDI canvas Pin
rohit.dhamija17-Feb-03 21:49
rohit.dhamija17-Feb-03 21:49 
GeneralRe: Dialog box before SDI canvas Pin
jhwurmbach17-Feb-03 21:55
jhwurmbach17-Feb-03 21:55 
QuestionHow to use vc to read the word doc file without office Pin
younker17-Feb-03 20:31
younker17-Feb-03 20:31 
AnswerRe: How to use vc to read the word doc file without office Pin
Stephane Rodriguez.17-Feb-03 21:07
Stephane Rodriguez.17-Feb-03 21:07 
GeneralControl List in SDI Pin
rohit.dhamija17-Feb-03 19:45
rohit.dhamija17-Feb-03 19:45 
GeneralRe: Control List in SDI Pin
Michael Dunn17-Feb-03 20:18
sitebuilderMichael Dunn17-Feb-03 20:18 
GeneralBitBlt function Pin
SatyaDY17-Feb-03 19:35
SatyaDY17-Feb-03 19:35 
Generalcanvas on SDI view Pin
rohit.dhamija17-Feb-03 18:10
rohit.dhamija17-Feb-03 18:10 

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.