Iím writing a macro for Excel 2010 that automatically creates and formats scatterplots. Even in this most recent version of
Excel, the choices for plot markers are a bit stingy, so Iíd like to augment the options for markers by utilizing Excel
shapes. Iíve included a file which contains a sample graph and a bit of code that demonstrates how Iíve gone about trying to
Chart2.Shapes.AddShape msoShapeMathMultiply, 0, 0, 15, 15
.Fill.ForeColor.RGB = RGB(0, 112, 192)
.Line.ForeColor.RGB = RGB(0, 0, 0)
.Line.Weight = 2
If you like these VB formatting tags please consider sponsoring the author in support of injured Royal Marines
If you open up the attached file and run the macro, youíll see that it draws an Excel shape (the multiply sign),
formats it, and then replaces the markers for one of the data series with the newly drawn shape. However, if you zoom in (go
to 400%) and compare the resolution of the shape itself vs. the new plot markers youíll see that the markers are a little
pixelated around the edges. While the difference may seem subtle, for my purposes this decline in resolution is not
acceptable. Iíve tried utilizing different options for the .CopyPicure command (e.g., xlScreen vs. xlPrinter), but this
doesnít make any difference.
Is there another way to programmatically use Excel shapes as custom plot markers
without losing resolution?