Microsoft Office Tutorials and References
In Depth Information
Table 15-3. Chart Properties
Name
Returns
Description
HasTitle
Boolean
Used to set whether the chart will display a chart title.
PlotBy
xlRowCol
Used to set whether columns in the original data are
used as individual data series (xlColumns) or if the
rows in the original data are used as the data series
(xlRows).
Table 15-4 lists the commonly used ChartObject property names and their results.
Table 15-4. ChartObject Properties
Name
Returns
Description
BottomRightCell
Range
Returns the single cell range located under the lower
right corner of the embedded ChartObject .
Chart
Chart
Returns the actual chart associated with the
ChartObject .
Height
Double
Sets the height of the embedded chart.
Left
Double
Sets the distance from the left edge of the margin to
the left edge of the ChartObject .
Name
String
Sets the name of the ChartObject .
PrintObject
Boolean
Sets whether the embedded object will be printed
when the worksheet is printed.
RoundedCorners
Boolean
Sets whether the embedded chart will have rounded
corners. By default, the property is set to False , which
displays right-angled corners.
Shadow
Boolean
Sets whether a shadow will appear around the
embedded chart.
Top
Double
Sets the distance of the Top edge of the ChartObject
to the top of the worksheet.
Visible
Boolean
Sets whether the ChartObject is visible.
Width
Double
Sets the width of the embedded chart.
Each object within the chart has a series of properties as well. For example, the ChartTitle
object can have a navy blue 2 point border or no border with a shadow. The ChartTitle can be
set using the position properties, such as Left and To p . In fact, the orientation can also be set.
When it comes to formatting a chart by enhancing the cosmetic appearance, the possibilities
are almost endless. Before programming the macro, modify an existing chart and document
the changes you have made to the chart. Now based on the sample chart and your documenĀ­
tation, add the appropriate lines of code to your procedure.
Search JabSto ::




Custom Search