ChartColumnSerie.Template

Syntax

Template: PP.Ui.ChartColumnTemplate | String;

Description

The Template property determines custom template of the chart series.

Comments

Use JSON or the setTemplate method to set the property value and the getTemplate method to get the property value.

The property is relevant on using custom templates.

Example

Executing the example requires the web application with opened instance of the express report containing selected chart with set custom template. It is required to enter code in the console:

// Get chart
dView = PP.App.getModuleObject().getReportBox().getDataView();
chart = dView.getChartView().getInstance();
// Get the first data series
firstSerie = chart.getSeries()[0];
// Get chart template object
templ = chart.getTemplate();
// Set manually another chart template
// Apply the first chart template to the first series
firstSerie.setTemplate(templ);
// Get preview object of the chart template
firstSerie.getPreview();
// ->  <canvas width=​"16" height=​"16">​

After executing the example alternative custom template was set for the first series.

See also:

ChartColumnSerie