Is it possible to show a 'k' in place of ',000' on a left axis--to reduce the required width of the axis label? I.E., rather then showing $100,000, I want to show $100k.
Note that I've tried the OnGetAxisLabel, the problem there is that screen size is a premium and the chart uses the width for the label without consideration of the smaller size.
Left Axis--showing thousands with 'k'
-
- Advanced
- Posts: 228
- Joined: Tue Aug 28, 2007 12:00 am
- Location: Oregon, USA
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi TestAlways,
In that case you can either add labels like this:
Or use custom axis labels as shown in the example at All Features\Welcome!\Axes\Labels\Custom labels
In that case you can either add labels like this:
Code: Select all
procedure TForm1.FormCreate(Sender: TObject);
var i: Integer;
val: double;
begin
for i:=0 to 10 do
begin
val:=100000*(i+1);
Series1.Add(val,'$'+FloatToStr(val/1000)+'k');
end;
Chart1.Axes.Left.LabelStyle:=talText;
Chart1.Axes.Bottom.LabelStyle:=talValue;
end;
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |