Reputation: 165
Is this shape drawable with .AddShape
?
Which is his MsoAutoShapeType
and how can I set the size of the internal circle?
Upvotes: 2
Views: 369
Reputation: 57693
To adjust the internal circle you need to generate the donut first,
.AddShape(MsoAutoShapeType, Left, Top, Width, Height)
where Width
and Height
define the outer circle. And then adjust the inner circle of the shape with
.DrawingObject.ShapeRange.Adjustments.Item(1) = 0.45
So we have something like this
Dim myShape As Shape
Set myShape = Worksheets("MySheetName").Shapes.AddShape(msoShapeDonut, 10, 10, 50, 50)
myShape.DrawingObject.ShapeRange.Adjustments.Item(1) = 0.45
and it looks like that:
For references see:
Upvotes: 2