Nimmi Srivastav replied on 20-Jan-07 08:38 PM
Is there a way to know the physical dimensions of a chart object on a
worksheet?  I have data in several worksheets and I would like all my
charts to be of the same size (obviously this means that data with a
smaller range of values will be more spread out than data with a larger
range of values).

Thanks,
Nimmi




Excel - Excel --- Physical dimensions of a chart object

Asked By GarysStuden on 21-Jan-07 08:17 AM
This is just an example:

Sub Macro2()
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.ChartArea.Select
n = ActiveSheet.Shapes("Chart 1").Width
m = ActiveSheet.Shapes("Chart 1").Height
MsgBox (n & " BY " & m)
End Sub

Note that you have to activate the chart AND select the ChartArea.
--
Gary''s Student
gsnu200702