Click here to Skip to main content
15,888,142 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: how to Convert MFC based Windows application to web application Pin
Richard MacCutchan9-Apr-14 6:24
mveRichard MacCutchan9-Apr-14 6:24 
GeneralRe: how to Convert MFC based Windows application to web application Pin
Munchies_Matt9-Apr-14 10:54
Munchies_Matt9-Apr-14 10:54 
Questionvisual c++ code to read number of characters in the string entered in a text box Pin
Member 107151068-Apr-14 16:14
Member 107151068-Apr-14 16:14 
AnswerRe: visual c++ code to read number of characters in the string entered in a text box Pin
David Crow8-Apr-14 16:48
David Crow8-Apr-14 16:48 
GeneralRe: visual c++ code to read number of characters in the string entered in a text box Pin
Munchies_Matt9-Apr-14 10:56
Munchies_Matt9-Apr-14 10:56 
AnswerRe: visual c++ code to read number of characters in the string entered in a text box Pin
leon de boer21-Apr-14 23:25
leon de boer21-Apr-14 23:25 
QuestionNeed help on MemDC , Drawtext() coding Pin
econy8-Apr-14 10:08
econy8-Apr-14 10:08 
AnswerRe: Need help on MemDC , Drawtext() coding Pin
leon de boer22-Apr-14 21:30
leon de boer22-Apr-14 21:30 
GetClientRect returns the area of the drawable area inside the window. It will usually return something like 0,0,width,height in your rect structure

GetWindowRect returns the co-ordinates of the Window itself relative to the upper left of the screen so they will be rather large.

If you try to use GetWindowRect co-ordinates to draw on the window they will be way outside the right and bottom and the drawing wont be visible unless you drag the window right up to the top left off screen.

You need to use GetClientRect co-ordinates to draw with.

Looking at your code I am guessing this line is the problem if you have a position problem

dc.BitBlt(137,107,176,50,&memDC,rect.left,rect.top,SRCCOPY);


Are you sure that is right?
QuestionCDC exist or not question Pin
econy8-Apr-14 2:28
econy8-Apr-14 2:28 
AnswerRe: CDC exist or not question Pin
econy8-Apr-14 2:37
econy8-Apr-14 2:37 
GeneralRe: CDC exist or not question Pin
CPallini8-Apr-14 4:02
mveCPallini8-Apr-14 4:02 
GeneralRe: CDC exist or not question Pin
econy8-Apr-14 4:29
econy8-Apr-14 4:29 
GeneralRe: CDC exist or not question Pin
CPallini8-Apr-14 11:09
mveCPallini8-Apr-14 11:09 
GeneralRe: CDC exist or not question Pin
econy8-Apr-14 12:47
econy8-Apr-14 12:47 
GeneralRe: CDC exist or not question Pin
CPallini8-Apr-14 21:36
mveCPallini8-Apr-14 21:36 
AnswerRe: CDC exist or not question Pin
Joe Woodbury24-Apr-14 9:30
professionalJoe Woodbury24-Apr-14 9:30 
QuestionSetWindowText Blinking problem Pin
econy7-Apr-14 6:00
econy7-Apr-14 6:00 
AnswerRe: SetWindowText Blinking problem Pin
Richard MacCutchan7-Apr-14 6:06
mveRichard MacCutchan7-Apr-14 6:06 
GeneralRe: SetWindowText Blinking problem Pin
econy7-Apr-14 6:46
econy7-Apr-14 6:46 
GeneralRe: SetWindowText Blinking problem Pin
Richard MacCutchan7-Apr-14 6:55
mveRichard MacCutchan7-Apr-14 6:55 
QuestionRe: SetWindowText Blinking problem Pin
David Crow7-Apr-14 16:39
David Crow7-Apr-14 16:39 
AnswerRe: SetWindowText Blinking problem Pin
willcoxson7-Apr-14 18:17
willcoxson7-Apr-14 18:17 
GeneralRe: SetWindowText Blinking problem Pin
econy8-Apr-14 2:26
econy8-Apr-14 2:26 
QuestionC++ - code executed upon definite program termination Pin
liquid_5-Apr-14 20:21
liquid_5-Apr-14 20:21 
AnswerRe: C++ - code executed upon definite program termination Pin
CPallini6-Apr-14 4:59
mveCPallini6-Apr-14 4:59 

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.