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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can't print datawindow in Not Collated (PB9)

Status
Not open for further replies.

early105

Programmer
Feb 17, 2004
3
US
Hi all,

I used PB9. I need to print a datawindow with several copies with not collated. That means, if the datawindow retrieved 3 pages, I want to print it in 2 copies. I can't print it this sequence: page 1, page 1, and then page 2 and page 2.

It always print in page 1 then page 2, and again.

No matter I've tried it in design time and run time.

I've tried to set the lstr_printdlg.s_printer.b_collate to False
before it run dw.print(). However, it still failed.

Then, I tried to print the datawindow in design time. The check box, collate copies, in 'print specification' was set to false.
And also uncheck the 'collate' in printer setup dialogue.
It also failed.

Does any successfull case to print a DW in not collated in PB9?

Please advise me. Thank you very much.
 
I suppose you already tried to change the DataWindow.Print.Collate property:
dw_1.modify(DataWindow.Print.collate=no)

Check if your printer driver supports the collate option?
Try it with the same printer in notepad.

An alternative might be to write code to set page.range to 1 then print it 2 times. Then set print.range to 2 and print 2 times, like this:

dw_1.modify(datawindow.print.range='1')
dw_1.print()
dw_1.print()

dw_1.modify(datawindow.print.range='2')
dw_1.print()
dw_1.print()
 
Thanks TheGreenOne,

I think the problem should be all about the printer driver, even though my current printer can print in 'Not collated' by testing with MS Word and Excel successfully. But it didn't work in my PB9 Application.

Fortunately, I've tested it with some others model of Printers (all of them could print in Collated or Not Collated), some of them works fine with PB.

I felt some disappointed with PB, this kind of problem wasted me a lot of time...

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top