Click here to Skip to main content
15,908,841 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: WM_PRINT Pin
Naveen10-Jun-08 21:31
Naveen10-Jun-08 21:31 
GeneralRe: WM_PRINT Pin
subramanyeswari10-Jun-08 21:38
subramanyeswari10-Jun-08 21:38 
GeneralRe: WM_PRINT Pin
Naveen10-Jun-08 21:48
Naveen10-Jun-08 21:48 
GeneralRe: WM_PRINT Pin
subramanyeswari10-Jun-08 22:25
subramanyeswari10-Jun-08 22:25 
GeneralRe: WM_PRINT Pin
Naveen10-Jun-08 22:34
Naveen10-Jun-08 22:34 
GeneralRe: WM_PRINT [modified] Pin
subramanyeswari10-Jun-08 22:48
subramanyeswari10-Jun-08 22:48 
GeneralRe: WM_PRINT Pin
Naveen10-Jun-08 23:15
Naveen10-Jun-08 23:15 
GeneralRe: WM_PRINT Pin
subramanyeswari10-Jun-08 23:24
subramanyeswari10-Jun-08 23:24 
Yes you are right CMemDC is our class. Here BitBlt fails because it is not one of active screen. Actual draw method is this
CWnd InTouch;

       InTouch.Attach(m_hWndParent);
       m_Parent.AttachExternalObject(this);

       //- ----------------------------------------
       //- control's parent window (a child of intouch)
       DWORD dwStyle = WS_CHILD |WS_VISIBLE;

       VERIFY(m_Parent.Create(NULL, "Invisible", dwStyle, DrawRect, &InTouch, 0));

       SetDrawMode (DRAWMODE_DESIGNTIME);


       Draw(&InTouch, DrawRect);

where m_Parent is a member of one of our class CInvisibleParent. before calling the actual drawing of the user control we are creating m_Parent by attaching InTouch. So BitBlt is failing.
GeneralRe: WM_PRINT Pin
Naveen10-Jun-08 23:37
Naveen10-Jun-08 23:37 
GeneralRe: WM_PRINT Pin
subramanyeswari11-Jun-08 18:57
subramanyeswari11-Jun-08 18:57 
GeneralRe: WM_PRINT Pin
Naveen11-Jun-08 19:11
Naveen11-Jun-08 19:11 
GeneralRe: WM_PRINT Pin
subramanyeswari11-Jun-08 21:00
subramanyeswari11-Jun-08 21:00 
GeneralRe: WM_PRINT Pin
Naveen11-Jun-08 21:09
Naveen11-Jun-08 21:09 
GeneralRe: WM_PRINT Pin
subramanyeswari11-Jun-08 21:51
subramanyeswari11-Jun-08 21:51 
GeneralRe: WM_PRINT Pin
Naveen11-Jun-08 21:58
Naveen11-Jun-08 21:58 
GeneralRe: WM_PRINT [modified] Pin
subramanyeswari12-Jun-08 0:21
subramanyeswari12-Jun-08 0:21 
GeneralRe: WM_PRINT Pin
Naveen12-Jun-08 1:00
Naveen12-Jun-08 1:00 
GeneralRe: WM_PRINT Pin
subramanyeswari12-Jun-08 1:21
subramanyeswari12-Jun-08 1:21 
AnswerRe: WM_PRINT Pin
James R. Twine11-Jun-08 2:05
James R. Twine11-Jun-08 2:05 
GeneralRe: WM_PRINT Pin
subramanyeswari11-Jun-08 19:02
subramanyeswari11-Jun-08 19:02 
QuestionHow can get Month and Year from selected date? Pin
Le@rner10-Jun-08 21:03
Le@rner10-Jun-08 21:03 
AnswerRe: How can get Month and Year from selected date? Pin
Cedric Moonen10-Jun-08 21:06
Cedric Moonen10-Jun-08 21:06 
GeneralRe: How can get Month and Year from selected date? Pin
Le@rner10-Jun-08 21:10
Le@rner10-Jun-08 21:10 
GeneralRe: How can get Month and Year from selected date? Pin
Cedric Moonen10-Jun-08 21:11
Cedric Moonen10-Jun-08 21:11 
GeneralRe: How can get Month and Year from selected date? Pin
Le@rner10-Jun-08 21:14
Le@rner10-Jun-08 21:14 

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.