Printing More than One Page (with graphics)
- From: "Marcelo" <marschio@xxxxxxx>
- Date: 28 Jun 2005 22:54:53 -0700
Greetings.
I develop a multiple forms applications with Microsoft Visual Studio
C++ .NET 2003 and I'd like to know how can I print more than one page
in my application. For printing one page, I do:
private: System::Void button1_Click(System::Object * sender,
System::EventArgs * e){
if(printDialog1->ShowDialog() == DialogResult::OK){
printDocument1->PrintPage += new PrintPageEventHandler(this,
&Form1::printDocument1_PrintPage); //Create the new event, for drawing
the page to print
printDocument1->Print(); //Once the page is ready, just print
it
}
}
private: System::Void printDocument1_PrintPage(Object* sender,
PrintPageEventArgs* ev){
ev->Graphics->Draw...//I make the drawings to print
ev->HasMorePages = false
}
It works perfectly. But I don't knnw how to print two graphics pages,
one after another. Must I draw the both pages in the
printDocument1_PrintPage event? In the MSDN they tell me to use the
SetMaxPage in an override CView::OnPreparePrinting function to draw
more than onepage. How could I do this?
Any help will be very appreciated.
.
- Follow-Ups:
- Re: Printing More than One Page (with graphics)
- From: Scot T Brennecke
- Re: Printing More than One Page (with graphics)
- Prev by Date: Re: Using a Class as parameter
- Next by Date: Re: An unhandled exception occurs when call ::AfxBeginThread()
- Previous by thread: An unhandled exception occurs when call ::AfxBeginThread()
- Next by thread: Re: Printing More than One Page (with graphics)
- Index(es):