>I have a client who has software developed with FoxPro 2.5. The reports are all developed and printed by .prgs. They want to be able to change the orientation from portrait to landscape and landscape to portrait progrmmatically. I suggested bringing up a dialog box...they didn't want to do it that way. My question is: How can I change report orientation programmatically?
>
>TIA for any help
Hi Michael,
One way to do it would be to include two report forms in the exe, one for portrait and one for landscape orientation. Then programmatically run the appropriate report form based on user input.
Another way to do it ( but maybe not a good one :-) ) is to distribute the report form and hack it on the fly. The record with Objtype=1 and Objcode=53 ( usually the first record ) has the printer related info. In the Expr field, I believe including:
ORIENTATION=0
sets the orientation to portrait and:
ORIENTATION=1
sets the orientation to landscape ( not sure on the values ).
I would probably opt for the first method.
Bill
William A. Caton III
Software Engineer
MAXIMUS
Atlanta, Ga.