PhpOffice/Tabelle Wie kann ich in ein Diagramm einen Wert für jede Spalte hinzufügen?

Post a reply

Smilies
:) :( :oops: :chelo: :roll: :wink: :muza: :sorry: :angel: :read: *x) :clever:
View more smilies

BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: PhpOffice/Tabelle Wie kann ich in ein Diagramm einen Wert für jede Spalte hinzufügen?

by Anonymous » 16 Aug 2025, 22:39

Ich verwende Phpoffice/PhpSpreadsheet, um in Excel ein Diagramm wie dieses zu produzieren:

, aber ich kann nicht feststellen. />
Dies ist der Code, den ich verwendet habe: < /p>



$yaxis = new Axis();
$xaxis = new Axis();
$xaxis->setAxisOptionsProperties('low', null, null, null, null, null, 0, 700, null, null);
$yaxis->setAxisOptionsProperties('low', null, null, null, null, null, -700, 700, null, null);
//$axis_labels, $horizontal_crosses_value = null, $horizontal_crosses = null, $axis_orientation = null, $major_tmt = null, $minor_tmt = null, $minimum = null, $maximum = null, $major_unit = null, $minor_unit = null
$chart = new Chart(
'chart1', // name
$title, // title
null, // legend
$plotArea, // plotArea
true, // plotVisibleOnly
0, // displayBlanksAs
null, // xAxisLabel
$yAxisLabel, // yAxisLabel
$xaxis,
$yaxis,
null,
null
);

$worksheet->addChart($chart);



Ist es möglich, dies mit PhpOffice/Tabelle zu tun?

Top