Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a worksheet with a number of embedded charts. In previous versions of
Excel within a macro I could loop through the charts that the user has selected (either one or more) by using code of the form: If (ActiveChart Is Nothing) Then For Each coChartObject In Selection coChartObject.Chart.HasTitle = True coChartObject.Chart.ChartTitle.Text = sInputBoxResponse Next coChartObject Else ActiveChart.HasTitle = True ActiveChart.ChartTitle.Text = sInputBoxResponse End If This code no longer works in 2007. What am I doing wrong? What code in 2007 can perform similarly? Note: If I select one chart the object type of the selection is ChartArea, if more than one chart is selected the object type of the selection is ChartObjects. In the case of the latter, the .Count of the ChartObjects is NOT equal to the number of charts that are selected, however, is equal to the number of charts in the worksheet. Thank you |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
looping through selected sheet tabs | Excel Programming | |||
Looping through charts in a worksheet | Excel Programming | |||
Looping through to stop on pie charts | Excel Programming | |||
Looping Through Charts | Excel Programming | |||
Looping Through Charts | Excel Programming |