I am trying to dynamically set the page size of a datawindow
from within a PB11.1 application. The datawindow is static
and the unit of measure for the DW is set to 1/1000 of a
centimeter. I want the user to be able to set the size of
the data window by entering a Height and Width value in
Centimeters.... I am using this code:
dw_1.SetRedraw(FALSE)
dw_1.Reset()
dw_1.SetTransObject(SQLCA)
dw_1.Modify("DataWindow.Print.Preview = 'Yes'")
dw_1.Modify("DataWindow.Print.Preview.Rulers= 'Yes'")
dw_1.Modify("DataWindow.Print.Paper.Size=256")
dw_1.Modify("DataWindow.Print.CustomPage.Width=80")
dw_1.Modify("DataWindow.Print.CustomPage.Length = 30")
dw_1.Retrieve()
dw_1.SetRedraw(TRUE)
From PB documentation this should set the page size to be
8cm by 3cm. The datawindow still looks like a full 8.5" by
11" page ? I would have expected it to to resize and show
the proper page size...
Any ideas on this would be appreciated. Thanks.
--
Report Bugs to Sybase: http://case-express.sybase.com/cx/welcome.do
Product Enhancement Requests:
http://my.isug.com/cgi-bin/1/c/submit_enhancement
<Blotto> wrote in message news:4b1fdb5f.22b...@sybase.com...
I am setting the paper size. See the code in the body of the
original post. The 'page size' wording was incorrect. I do
see a blue rectangle but regardless of what I set the paper
size to it never changes...
Try to multiply your values by 100.
Also, have you experimented with any additional adjustment of
Datawindow.Print.Margin.Top/Bottom/Left/Right?
Regards,
Ivaylo
<Blotto> wrote in message news:4b1fdb5f.22b...@sybase.com...
"Ivaylo Ivanov" <n0_S_p_a_...@isy-dc.com> wrote in message
news:4b20bd38@forums-1-dub...