Protected Sub viewer_BeforeRenderObject(ByVal source As Object, ByVal e As CrystalDecisions.Web.HtmlReportRender.BeforeRenderObjectEvent) Handles Viewer.BeforeRenderObject
'Make sure where dealing with the right type of object
If TypeOf e.Object Is ViewerObjectModel.ReportObjectInstance Then
Dim ro As ViewerObjectModel.ReportObjectInstance = DirectCast(e.Object, ViewerObjectModel.ReportObjectInstance)
Dim cls As String = String.Empty
' Check for rotation
Select Case ro.ObjectFormat.Rotation
Case 90
cls = "rotate90"
Case 270
cls = "rotate270"
End Select
ro.ObjectFormat.StyleSheetName = cls
End If
End Sub
'Make sure where dealing with the right type of object
If TypeOf e.Object Is ViewerObjectModel.ReportObjectInstance Then
Dim ro As ViewerObjectModel.ReportObjectInstance = DirectCast(e.Object, ViewerObjectModel.ReportObjectInstance)
Dim cls As String = String.Empty
' Check for rotation
Select Case ro.ObjectFormat.Rotation
Case 90
cls = "rotate90"
Case 270
cls = "rotate270"
End Select
ro.ObjectFormat.StyleSheetName = cls
End If
End Sub
Comments