View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.charting
Jon Peltier
 
Posts: n/a
Default Moving data labels around with VBA (and adding a line between two

I follow a methodology which is a little more complicated in the chart, but
much less so in VBA (in fact, it requires NO VBA).

For each set of labels I need, I add a line chart (or XY chart) series to
the chart, with X and Y values selected to precisely locate the label with
respect to the floating columns. Various formulas adjust these X and Y as
needed to move the labels to align with the columns. The added series are
formatted to be hidden (no line, no markers). Then I use one of these free
Excel add-ins to apply the appropriate datalabels to the points. Once
applied, I never need to readjust them, because the datalabel text is linked
to the cells in the worksheet that contain the text for the labels.

Rob Bovey's Chart Labeler, http://appspro.com
John Walkenbach's Chart Tools, http://j-walk.com/ss

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______

"Caro-Kann Defence" wrote in
message ...
Hello.

I am looking for a way to manage data labels in an automated charting
procedure I am writing.

The chart is a waterfall chart (I believe) and I'd like to be able to loop
through each dataseries/column to find the height of the total column and
then set the label for the total column to sit x points above it.

There is a second issue I need help with. As the chart displays components
of return for stocks and bonds, I'd like to place a line in between the
last
stock and the first bond shown. Is there a way that I can place this line
dynamically (charts will like have different numbers of stocks and bonds -
as
will a particular chart over time).

I think there is an add-in someone mentioned I could try downloading but
I'd
like to avoid that if possible.

Thanks,
Caro-Kann Defence