Kelvin Stott
Active Member
- Joined
- Oct 26, 2010
- Messages
- 338
Hello,
I've been trying to add simple filled shapes (rectangle) onto my XY scatter plot in VBA. I tried using the following, but the coordinates don't match up with the xy coordinates on the plot, and seems to draw outside the plot:
Could somebody please let me know what I'm doing wrong?
I've been trying to add simple filled shapes (rectangle) onto my XY scatter plot in VBA. I tried using the following, but the coordinates don't match up with the xy coordinates on the plot, and seems to draw outside the plot:
Code:
With MyChart.Shapes.AddShape(msoShapeRectangle, 10, 10, 20, 20)
.Name = "IQR"
.Fill.ForeColor.RGB = RGB(255, 153, 0)
End With
Could somebody please let me know what I'm doing wrong?