Send Topic Feedback | See Object Hierarchy Chart
PC-DMIS 2023.1 Object Library
Rotation Property
Description
Read/Write: Returns/Sets via dmis matrix the transformations/rotation on the CAD Report Control
Property type
Read-write property
Syntax
Visual Basic
Public Property Rotation As DmisMatrix
Return Type
Returns a DmisMatrix object.
Example
Rotates the Cad Report Object by the typed degrees:
Dim DmisApp As Object
Dim DmisPart As Object
Dim DmisReport As Object
Dim ReportPages As Object
Dim ReportPage As Object
Dim RepControls As Object
Dim RepControl As Object
Dim Rotate As Object
Dim I As Integer

Sub Main2

  Set DmisApp = CreateObject("PCDLRN.Application")
  Set DmisPart = DmisApp.ActivePartProgram
  Set DmisReport = DmisPart.ReportWindow
  Set ReportPages = DmisReport.Pages

  For Each ReportPage In ReportPages
     Set RepControls = ReportPage.ReportControls
     For I = 1 To RepControls.Count
       Set RepControl = RepControls.ItemControl(I)
       If (RepControl is Nothing) Then
          MsgBox "Nothing"
       Else
          If RepControl.Type = 26514 Then
            Set Rotate = RepControl.Rotation
            intDegees = InputBox ("Type the degrees by which to rotate the CRO:","CRO Rotate")
            Rotate.RotateByAngle intDegees, 1
            Set RepControl.Rotation = Rotate
            Set Rotate = Nothing
        End If
       End If
     Next I
  Next ReportPage 

DmisReport.RefreshReport

Set ReportPages = Nothing
Set DmisReport = Nothing
Set DmisPart = Nothing
Set DmisApp = Nothing
  
End Sub

Sub Main
   Main2
End Sub
See Also