InsertChart()

IShapeCollection::InsertChart(Charts::ChartType, float, float, float, float, int32_t) method

Creates a new Chart, initialize it with sample series data and settings and inserts it to the specified position in the collection.

virtual System::SharedPtr<Charts::IChart> Aspose::Slides::IShapeCollection::InsertChart(Charts::ChartType type, float x, float y, float width, float height, int32_t index)=0

Arguments

ParameterTypeDescription
typeCharts::ChartTypeType of chart.
xfloatX coordinate of a new chart.
yfloatY coordinate of a new chart.
widthfloatChart’s width.
heightfloatChart’s height.
indexint32_tChart’s position in the collection.

Return Value

Created chart.

IShapeCollection::InsertChart(Charts::ChartType, float, float, float, float, int32_t, bool) method

Creates a new Chart and inserts it to the specified position in the collection.

virtual System::SharedPtr<Charts::IChart> Aspose::Slides::IShapeCollection::InsertChart(Charts::ChartType type, float x, float y, float width, float height, int32_t index, bool initWithSample)=0

Arguments

ParameterTypeDescription
typeCharts::ChartTypeType of chart.
xfloatX coordinate of a new chart.
yfloatY coordinate of a new chart.
widthfloatChart’s width.
heightfloatChart’s height.
indexint32_tChart’s position in the collection.
initWithSampleboolIf true then new chart will be initialized with sample series data and settings. If false then new chart will have no series and minimum settings. In this case chart creation will be more fast.

Return Value

Created chart.

See Also