VBA-Programmierung in Microsoft Excel

Tutorial: Excel-Beispiele

VBA-Begriff: Beispiel zur RotationY-Eigenschaft

In diesem Beispiel werden in myDocument drei identische projizierte Ellipsen eingefügt und für ihre Drehung um die X-Achse ein Wert von -30, 0, bzw. 30 Grad festgelegt.

Set myDocument = Worksheets(1)
With myDocument.Shapes
    With .AddShape(msoShapeOval, 30, 30, 50, 25).ThreeD
        .Visible = True
        .RotationY = -30
    End With
    With .AddShape(msoShapeOval, 30, 70, 50, 25).ThreeD
        .Visible = True
        .RotationY = 0
    End With
    With .AddShape(msoShapeOval, 30, 110, 50, 25).ThreeD
        .Visible = True
        .RotationY = 30
    End With
End With