Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

printdocument problem

Status
Not open for further replies.

JScannell

Programmer
Jan 9, 2001
306
US
I'm inheriting some code and I need to streamline it. I don't have that much experience with setting up a completed printdocument object to print. Here's what I'd like to do without a lot of trouble:
1. Have the user select if they want the printdocument to go directly to the default printer or to a .pdf file
2. If .pdf is chosen, then allow them to enter in the desired file name. (I will default to path to something user-specific)
3. When the printdocument is finished, have it go either to the default printer or create/overwrite the desired .pdf document as soon as they are finished.

I would like to do this without having to go through a printdialog object like it currently does. The app is written in VS 2005 and one of the issues I have with that version of VS is that it is nearly impossible to see what is happening with an embedded object like a printdialog. I cannot find where the printdialog code is called so I can't pre-populate it with the necessary information. Plus, the app produces several documents and each one has its own "save" dialog popup as the reports are being generated with a default of "document.pdf" when .pdf is chosen. This is a real nuisance now and will only get worse as more printdocument objects are created.

I want to add checkboxes/radiobuttons and text entry fields so the user can select whatever they want for each of the printdocument objects and then let her go.

Thanks in advance,

Jerry Scannell
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top