Get KoolPHP UI with 30% OFF!

Colors in column/bar chart

Primoz Mejac
Hi,
Is it possible to set different color or pattern for each bar or column in the same serial
thanks
primoz
Posted Aug 17, 2017 Kool
Anthony Amolochitis
I believe you can just set it to any web safe color.
http://doc.koolphp.net/Controls/KoolChart/index.php
Posted Aug 21, 2017 Kool
Primoz Mejac
Yes, but I would like to set color for one bar in the same serial. eg.
Serial Q1 (red)
Serial Q2 (blue) - inside this serial I want just for the 5th bar different color e.g. black - all others should remain in blue.
is this even posible?
thanks
primoz
Posted Aug 21, 2017 Kool
Anthony Amolochitis
    $series = new BarSeries("");
    $series->Name = "Leads";
    $series->Appearance->BackgroundColor = "lightblue"; // set the color here 
    $series->LabelsAppearance->DataFormatString = "{0}";
    $series->LabelsAppearance->FontColor= 'grey' ;
    $series->LabelsAppearance->FontWeight = 'bold';
    $series->LabelsAppearance->FontSize = '12px';
    $series->TooltipsAppearance->DataFormatString = "Leads: {0}";
    $series->ArrayData( $CampaignStatisticsGeneralReport->GetLeadCountByResponseType() );
    $breakout->PlotArea->AddSeries($series);
Posted Aug 21, 2017 Kool