By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,871 Members | 2,575 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,871 IT Pros & Developers. It's quick & easy.

crystal report print-to-printer

P: 6
Hello!
I would like to print a crystal report by using command line
Expand|Select|Wrap|Line Numbers
  1. mydoc1.PrintToPrinter(1, False, 1, 2)
..but every time the program come to this line, starts doing I don't know what and nothing happens for a long time.
I set up PrinterOptions.PrinterName to match my printer.
The same happens if I click the printer icon in printpreview screen, but if I click printer icon under Main Report Preview (when program is stopped) it works OK.
I would be grateful for any suggestions.
Jernej
Apr 22 '08 #1
Share this Question
Share on Google+
2 Replies


P: 4
Hello!
I would like to print a crystal report by using command line
Expand|Select|Wrap|Line Numbers
  1. mydoc1.PrintToPrinter(1, False, 1, 2)
..but every time the program come to this line, starts doing I don't know what and nothing happens for a long time.
I set up PrinterOptions.PrinterName to match my printer.
The same happens if I click the printer icon in printpreview screen, but if I click printer icon under Main Report Preview (when program is stopped) it works OK.
I would be grateful for any suggestions.
Jernej
hi there..wut language r u using..?
hv u tried checking ur report destination..whether it's window(0), printer(1) ...etc
Apr 28 '08 #2

Tenneyson
P: 17
Hello!
I would like to print a crystal report by using command line
Expand|Select|Wrap|Line Numbers
  1. mydoc1.PrintToPrinter(1, False, 1, 2)
..but every time the program come to this line, starts doing I don't know what and nothing happens for a long time.
I set up PrinterOptions.PrinterName to match my printer.
The same happens if I click the printer icon in printpreview screen, but if I click printer icon under Main Report Preview (when program is stopped) it works OK.
I would be grateful for any suggestions.
Jernej
Hi there!

If you are using VB, u may wanna add the following to let your program know that it has finished printing or sending the document

Expand|Select|Wrap|Line Numbers
  1. mydoc1.PrintToPrinter(1, False, 1, 2)
  2. Printer.EndDoc
  3. Printer.NewPage
  4.  
Apr 29 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.