Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to change the leyend in a chart?

Status
Not open for further replies.

migueleitor

Programmer
Jan 15, 2004
22
VE
hi, does anyone know how to change the leyend in a chart? i'm trying , but i can't. thank you very much
 
You can loop through the comumn collection and then use the column lable propperty to change the text of the legend.

With MSChart1
.Column = 1 'columnNumber
.ColumnLabel = "Whatever"
end with

**********************************
May the Code Be With You...
----------
x50-8 (X Fifty Eigt)
 
ok , i have done it, but when the leyend show up, it has C1, ... Cn, why?

i wrote this

With Me.MSChart1
Do While i <> 5
.Column = i 'columnNumber
.ColumnLabel = &quot;Whatever&quot;
i = i + 1
Loop
End With

vcrearreportetecnologiafecha.MSChart1.ShowLegend =
True

thank you



 
With Me.MSChart1

For i = 0 to 5
.Column = i 'columnNumber
.ColumnLabel = &quot;Whatever&quot;
next i

End With


**********************************
May the Code Be With You...
----------
x50-8 (X Fifty Eigt)
 
hey , it's the same thing,

i meant when the legend show up, it has c1,... cn, if i wrote what u sent or mine.

what should i do?
 
Do know....

Why don't you debug and step through your code to see what actually happens there...

Mine is like that and works fine

**********************************
May the Code Be With You...
----------
x50-8 (X Fifty Eigt)
 
hey, i don't know why it doesn;t work. i ran step by step and the columnlabel get the name but the legend doesn't show what the columnlabel gets.

Do u have all code to see who u do it.

thank you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top