SqueakinSweep
Programmer
I have a CR, which is a landscape report. I populate it with data, pass it to a viewer which I dont show to the user, and instead export directly to a PDF file. The output always appears portrait. Does anyone any ideas how I force it to be landscape. The code below is the New Event of my subclassed Crystal Report. The only Landscape setting I can find is in the PrintOptions?
Sweep
...if it works dont mess with it
Code:
Public Sub New(ByVal sReporttoLoad As String, _
Optional ByVal sPaperSize As String = "A4", _
Optional ByVal bLandScape As Boolean = False)
Me.bLoaded = False
Me.zLoadReport(sReporttoLoad)
Select Case sPaperSize.ToUpper
Case "A4"
Me.oReport.PrintOptions.PaperSize = PaperSize.PaperA4
Case "A3"
Me.oReport.PrintOptions.PaperSize = PaperSize.PaperA3
End Select
If bLandScape Then Me.oReport.PrintOptions.PaperOrientation = PaperOrientation.Landscape
End Sub
Sweep
...if it works dont mess with it