PDA

View Full Version : Mschart Control


longingfriend
09-09-03, 15:29
Can anybody help me in showing the values on top of the bar . I am using MSCHART

For example in Excel the following will display the values on top of the bar
ActiveChart.ApplyDataLabels Type:=xlDataLabelsShowValue

shivdev124
11-03-03, 01:57
Hi, dude


You can copy this piece of code after loading your code


With MSChart1
Set .DataSource = rs
For i = 1 To .Plot.SeriesCollection.Count
With .Plot.SeriesCollection(i).DataPoints(-1).DataPointLabel
.LocationType = VtChLabelLocationTypeOutside
.Component = VtChLabelComponentPercent
.PercentFormat = "0%"
.VtFont.Size = 12
End With
Next i
End With



hope it works, just make the necessary changes.