![]() |
Hilfe bei TChart - BottomAxis
Liste der Anhänge anzeigen (Anzahl: 1)
Nabend Leute,
komme heute das erste mal mit TChart in Berührung und habe gleich Probleme. Die Beschriftung der "BottomAxis" möchte ich so hinbekommen wie auf dem Screenshot aus einem Excel Diagramm. Scheitere aber daran kläglich. Könntet Ihr mir mal auf die Sprünge helfen... Vielen Dank.
Delphi-Quellcode:
procedure TForm1.Button1Click(Sender: TObject);
var i, w: integer; d: double; s:String; begin randomize; // chart1.BottomAxis.Items.Automatic := false; // chart1.BottomAxis.Items.Clear; for i:= 0 to 11 do begin d:=0; w:=0; s:='Test - '; w:=Random(100); d:=Random(99)/100; d:=d+w; s:=s+inttostr(i+1); chart1.Series[0].AddY(d,s); // chart1.BottomAxis.Items.Add(d,inttostr(i)+'s'); end; end; |
AW: Hilfe bei TChart - BottomAxis
Liste der Anhänge anzeigen (Anzahl: 1)
Edit: - Screenshot vom Testprojekt mit TChart hinzugefügt (ging leider nicht beim editieren des Beitrags - Sorry)...
|
AW: Hilfe bei TChart - BottomAxis
Eigentlich einfach
Delphi-Quellcode:
ungetestet übers Handy getippt.
series1.add(100,'X-Beschriftung', clRed)
|
AW: Hilfe bei TChart - BottomAxis
Eine Achse hat eine Eigenschaft "DateTime" oder so ähnlich. Da kannst du als X-Wert einfach einen TDateTime-Wert eintragen, der TeeChart übernimmt den Rest, also dass auf der X-Achse immer ein Datum und keine simple Zahl dransteht.
|
AW: Hilfe bei TChart - BottomAxis
Vielen Dank Euch zwei. Hat funktioniert...
Mfg Thomas |
Alle Zeitangaben in WEZ +1. Es ist jetzt 11:01 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz