Click here to Skip to main content
15,910,878 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Custom Buttons Using CDialogBar, CButton, and CControlBar :: MFC Pin
valikac23-May-02 19:29
valikac23-May-02 19:29 
GeneralPrinting C/C++ source code in color Pin
SAK23-May-02 12:38
SAK23-May-02 12:38 
GeneralRe: Printing C/C++ source code in color Pin
Martin Ziacek23-May-02 19:34
Martin Ziacek23-May-02 19:34 
GeneralFile->Open Pin
Stew23-May-02 12:03
Stew23-May-02 12:03 
GeneralRe: File->Open Pin
Stew23-May-02 12:29
Stew23-May-02 12:29 
GeneralPrinting Question Pin
Stew23-May-02 10:31
Stew23-May-02 10:31 
GeneralRe: Printing Question Pin
Stew23-May-02 11:18
Stew23-May-02 11:18 
GeneralRe: Printing Question Pin
Jonathan Craig23-May-02 11:18
Jonathan Craig23-May-02 11:18 
The GetClientRect(...) method always returns the size of the client area on the screen, even when printing. You need to use something like the CPrintInfo::m_rectDraw when drawing to the printer. You can save the print rect in CView::OnBeginPrinting(...) and use the pDC->IsPrinting() to flag using the printer rect vs. the client rect.

This opens up a whole can of worms when trying to use your dynamic screen drawing code to draw to the more static printer page. There are other ways to get the printer page information. Search the MSDN for "get default print info" and see what you get. Of course this all opens a bigger can of worms.

You may want to just try using CPrintInfo::m_rectDraw first. It may be all you need.

Good Luck Smile | :)

Jonathan Craig
www.mcw-tech.com
GeneralSetWindowsHookEx Problem...... Pin
DeepBlue23-May-02 10:06
DeepBlue23-May-02 10:06 
QuestionCan RDS.Dataspace be used from Visual C++ Pin
Jesper Mandal Hansen23-May-02 9:45
Jesper Mandal Hansen23-May-02 9:45 
GeneralWebBrowser control Pin
Sanjeev Kumar23-May-02 9:15
Sanjeev Kumar23-May-02 9:15 
GeneralRe: WebBrowser control Pin
Ravi Bhavnani23-May-02 12:17
professionalRavi Bhavnani23-May-02 12:17 
QuestionWhats wrong with this code? Pin
Mazdak23-May-02 8:52
Mazdak23-May-02 8:52 
AnswerRe: Whats wrong with this code? Pin
Joaquín M López Muñoz23-May-02 8:59
Joaquín M López Muñoz23-May-02 8:59 
GeneralRe: Whats wrong with this code? Pin
Mazdak23-May-02 9:21
Mazdak23-May-02 9:21 
GeneralRe: Whats wrong with this code? Pin
Joaquín M López Muñoz23-May-02 9:31
Joaquín M López Muñoz23-May-02 9:31 
GeneralRe: Whats wrong with this code? Pin
Mazdak23-May-02 9:41
Mazdak23-May-02 9:41 
AnswerRe: Whats wrong with this code? Pin
Philip Patrick23-May-02 8:59
professionalPhilip Patrick23-May-02 8:59 
GeneralRe: Whats wrong with this code? Pin
Mazdak23-May-02 9:27
Mazdak23-May-02 9:27 
AnswerRe: Whats wrong with this code? Pin
Neville Franks23-May-02 12:42
Neville Franks23-May-02 12:42 
GeneralDisplaying version Pin
User 988523-May-02 8:02
User 988523-May-02 8:02 
GeneralRe: Displaying version Pin
Prem Kumar23-May-02 8:16
Prem Kumar23-May-02 8:16 
GeneralLinker error when using DirectDrawCreateEx(...) Pin
Alan Chambers23-May-02 7:51
Alan Chambers23-May-02 7:51 
GeneralRe: Linker error when using DirectDrawCreateEx(...) Resolved Pin
Alan Chambers23-May-02 8:52
Alan Chambers23-May-02 8:52 
GeneralOutlook (Express) Automation Pin
peterchen23-May-02 6:54
peterchen23-May-02 6:54 

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.