1. Stefan Malkwitz
  2. PowerBuilder
  3. Thursday, 17 November 2022 07:37 AM UTC

Hello everyone,


As the title says, here's the question. Can you rotate a data window 90 degrees?


Our problem:
We want to print 2 datawindows one after the other. The first one with normal orientation (portrait).
The second one rotated 90 degrees on an landscape orientation.
Without changing anything in the printer driver.


Questions:
Is it even possible?
How can we achieve it?
How would you handle that if you have this problem?


thank you everyone and have a nice day
greetings Stefan

Attachments (1)
Andreas Mykonios Accepted Answer Pending Moderation
  1. Thursday, 17 November 2022 08:07 AM UTC
  2. PowerBuilder
  3. # 1

Hi.

So you need to set for the first datawindow orientation to portrait and the second to landscape? This would be done like that:

dw_1.Object.DataWindow.Print.Orientation = 2 // portrait
dw_2.Object.DataWindow.Print.Orientation = 1 // landscape

Or it is something more complex?

Andreas.

Comment
  1. Stefan Malkwitz
  2. Thursday, 17 November 2022 11:40 AM UTC
i will try this :) thx
  1. Helpful
There are no comments made yet.
Sivaprakash BKR Accepted Answer Pending Moderation
  1. Thursday, 17 November 2022 11:00 AM UTC
  2. PowerBuilder
  3. # 2

Hello,
Would like to have more information.

1.   Seems the final outcome is in Landscape mode.
2.   Print has to be done side by side and NOT one after another.

Though I haven't tried.
Side by Side printing could be done with nested report, provided that it contains only detail band [ NO header band, NO footer band]

HTH

Happiness Always
BKR Sivaprakash

 

Comment
  1. Stefan Malkwitz
  2. Thursday, 17 November 2022 11:45 AM UTC
We want to print 2 different datawindows one after another with 2 different dataobjects.



Code example:



dw_1.dataobject = "dataobject_1"

dw_2.dataobject = "dataobject_2"

...some Code...

dw_1.print() // portrait

dw_2.print() // landscape

...some Code...
  1. Helpful
  1. Sivaprakash BKR
  2. Thursday, 17 November 2022 12:50 PM UTC
I thought it's a side by side printing. Try what Andreas suggested. You can also try with PrintOpen & PrintClose commands along with proper orientation settings either in script or in datawindow properties.



long job

job = PrintOpen( )

// Each DataWindow starts printing on a new page.

PrintDataWindow(job, dw_1)

PrintDataWindow(job, dw_2)

PrintDataWindow(job, dw_3)

PrintClose(job)

  1. Helpful 1
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.