Show TOC

Smart Area Micro ChartLocate this document in the navigation structure

The sap.ui.comp.smartmicrochart.SmartAreaMicroChart control creates a sap.suite.ui.microchart.AreaMicroChart control based on OData metadata.

By using the chartType property Area of the UI.Chart annotation the corresponding SmartAreaMicroChart control is rendered. The entitySet attribute must be specified to use the control. This control property is used to fetch the corresponding annotations. Based on this, the AreaMicroChart will be rendered; it can also be used to fetch the actual chart data.

Note The control can also be used directly (without creating a SmartMicroChart).

The SmartAreaMicroChart control supports only enableAutoBinding = true. Thus it should be bound to only one entitySet, and should get a navigation property as a chartBindingPath to an entitySet (for the relative binding) or else the entitySet property will be used for the absolute binding.

Color of the Chart bar

For more information about the colors in the chart, see the sample in the Explored app in the Demo Kit.




Title, Description and UnitOfMeasure

The control provides Title, Description and UnitOfMeasure values retrieved from the annotations. If needed, the application can create a corresponding chartTitle, chartDescription or unitOfMeasure (of type sap.m.Label) association. Then, the information will be read from the annotation document and it will be set as the text property of the sap.m.Label.

  • Title and Description

    For the Title and Description properties of the Chart annotation both String and Path are supported:

    • <PropertyValue Property="Title" Path="ChartTitle" />
    • <PropertyValue Property="Title" String="ChartTitle" />
    Note Only the Title and Description properties of the Chart annotation are taken into account (not these of the DataPoint annotation).

    For the SmartAreaMicroChart control, the Title, Description and UnitOfMeasure have the same binding context as the chart itself (either chartBindingPath or entitySet).

  • UnitOfMeasure

    For more information about the supported annotation terms ISOCurrency and Unit, see published on non-SAP site.

    The control takes into account only the measure annotation for the entityType property which is addressed by the Value property of the DataPoint annotation. In the following example, the Value property of the DataPoint is pointing to the Price property in the EntityType (Path="Price"). Thus the measure annotation with Target="AmcNamespace.StockPrice/Price" is used by the control (Path="Currency"):

    <EntityType Name="StockPrice">
    <Property Name="Currency" Type="Edm.String" />
    <Annotation Term="UI.DataPoint" Qualifier="AreaChartDataPoint">
    <PropertyValue Property="Value" Path="Price" />
    <Annotations xmlns="" Target="AmcNamespace.StockPrice/Price" >
    	<Annotation Term="MEASURES.ISOCurrency" Path="Currency">