Hello,
We have TeeChart Pro V7.05 VCL, what I was wanting to do is display wind direction on a time series chart. In doing so I was wanting to both display 0-360 degrees and also a N,S,W,E label. Is this possible ? I was looking at the TAxisLabelTool component but couldn't find anything in the help file on it ?
TIA,
Brett.
Changing axis labels
Hi, Brett.
I think this is the best approach (using custom labels to fully customize axis labels).
I think this is the best approach (using custom labels to fully customize axis labels).
Marjan Slatinek,
http://www.steema.com
http://www.steema.com
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi James,
I already replied to the message you posted in the ActiveX forum.
Regarding custom labels, you can find an example at TeeChart's features demo. The example can be found at All Features\Welcome!\Axes\Labels\Custom Labels.
I already replied to the message you posted in the ActiveX forum.
Regarding custom labels, you can find an example at TeeChart's features demo. The example can be found at All Features\Welcome!\Axes\Labels\Custom Labels.
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 |
Re: Changing axis labels
I recently found it's just a demo example of a Custom Chart Tool class located in Examples\Features\TeeAxisLabelTool.pas.9236183 wrote:I was looking at the TAxisLabelTool component but couldn't find anything in the help file on it ?
TIA,
Brett.
In one of my programs I used
Code: Select all
procedure TForm2.chWGetAxisLabel(Sender: TChartAxis; Series: TChartSeries;
ValueIndex: Integer; var LabelText: String);
var
X:double;
Code:integer;
begin
if Sender=chW.BottomAxis then
begin
Val(LabelText,X,Code);
if (Round(X)=0) or (Round(X)=360) then
LabelText:='N'
else
if Round(X)=90 then
LabelText:='E'
else
if Round(X)=180 then
LabelText:='S'
else
if Round(X)=270 then
LabelText:='W'
else
Str(X:3:0,LabelText);
end;
end;
Regards, Alexander
=================
TeeChart Pro v8.05, Delphi 5 & Turbo Delphi Professional for Win32., Delphi & C++Builder 2009
=================
TeeChart Pro v8.05, Delphi 5 & Turbo Delphi Professional for Win32., Delphi & C++Builder 2009