Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I have dozens of similar bar charts, each with 8 bars. I would like to place each bar's lable adjacent to its bottom if it's negative, or adjacent to its top if it's positive. My problem is that when the data changed the bar size will charge accrodingly, but the lables don't move at all. I have to manually put them to the right places. Could some one help me with some codes so that the lable will move with its bar when the data change. Thank you very much in advance. Regards, Michael |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi micahel
try this Sub position_labels() For Each ss In ActiveChart.SeriesCollection values_array = ss.Values For n = 1 To ss.Points.Count If values_array(n) < 0 Then ss.Points(n).DataLabel.Position xlLabelPositionInsideBase Else ss.Points(n).DataLabel.Position xlLabelPositionOutsideEnd Next Next End Su -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Need help positioning data labels | Charts and Charting in Excel | |||
Auto positioning of labels outside pie slices | Charts and Charting in Excel | |||
Positioning a drawn line shape on a chart | Charts and Charting in Excel | |||
Unlocking The Positioning Grid And Printing Question | New Users to Excel | |||
excel chart size using inside positioning | Charts and Charting in Excel |