Not all printers/drivers store the duplex settings the same in FRX.
A client of ours wanted all of their reports to default to duplex (print both sides) if the printer they were using supported it. We didn't think this would be a problem, but... Here is what we found:
PrtInfo function says the following about what duplex values could be returned:
Simplex Printing = 1 (what the heck is simplex printing?)
Vertical Duplex = 2
Horizontal Duplex = 3
For landscape reports, we wanted vertical, for portrait, we wanted horizontal.
Here is the nomenclature used in our HP5si driver:
Flip on Long Edge
Flip on Short Edge
So, we ran with DUPLEX=2 for both landscape and portrait (since we always wanted long edge for either) - this worked great on the HP5si.
Now, the client is running their duplexing on HP4500 and HP4550 printers. Here is the nomenclature used in those drivers:
Flip Pages Up
Booklet Printing (Off, Letter Left, Letter Right, Legal Left, Legal Right)
Huh? Now, to make matters worse, to get the same results by default that we get on the 5si in our development and test environment, here is what we had to set in Expr in the client site's FRX:
For Portrait: DUPLEX = 2 (still the same as before)
For Landscape: DUPLEX = 3 <-this totally hosed us!
Now, I would venture to guess this is an HP problem (not programming to interface!) vs. a Visual Foxpro problem, but I could be wrong. Anyway, we just had to modify our Tag/Tag2 clearing routine but it was really a pain to track down why they could not duplex (or pages flipped incorrectly) by default when it worked fine for us here using same FRX files.
Contributors: Randy Jean
Category VFP Reports
( Topic last updated: 2002.07.01 07:43:41 PM )