Hi All,
I wondered if somebody could help me with this problem. I am using a
Macintosh and trying to print from a listbox. When I show the print dialog,
I may choose to just print pages 1 to 3, but the report prints everything.
How can I just get it to print the pages I have requested.
My code is as follows:
p = new printerSetup
If gthePageSettings <> "" then
p.SetupString = gthePageSettings
Else
If p.PageSetupDialog Then
gthePageSettings=p.SetupString
End If
End
g = openPrinterDialog(p)
If g <> nil then
pageWidth = p.PageWidth
pageHeight = p.PageHeight
iend = previewList.listcount - 1
imid = previewList.listcount - 1
//do setup here
pageNumber = 1
g.textfont="Times New Roman"
g.bold = false
g.textsize = 12
ifieldTotal = previewList.columnCount - 1
iTop = lTop - p.top + 10
iLabelTop = iTop
For i = 0 to iend
//print g.strings here from the listbox
If iTop > pageHeight - lHeight - lGap - lBottom then
pageNumber = pageNumber + 1
g.NextPage
iTop = lTop + 10
iLabelTop = iTop
End
If icount = iend then exit
Next
End
Thanks very much.
Cindy
--
Cindy Brown
Programmer
SchoolMaster
Kowhai Programming Systems
PO Box 191, Invercargill
81 Marama Avenue South, 9RD Invercargill
Phone (03) 213 1243
Fax (03) 213 1248
Mobile (021) 354 930
<http://www.kowhaiprogramming.com/>
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>