RemoveAt
ChartSeriesGroupCollection.RemoveAt method
Tar bort en seriegrupp vid det angivna indexet. Alla underserier tas bort från diagrammet.
public void RemoveAt(int index)
Exempel
Visa hur man tar bort sekundäraxeln.
Document doc = new Document(MyDir + "Combo chart.docx");
Shape shape = (Shape)doc.GetChild(NodeType.Shape, 0, true);
Chart chart = shape.Chart;
ChartSeriesGroupCollection seriesGroups = chart.SeriesGroups;
// Hitta sekundäraxeln och ta bort den från samlingen.
for (int i = 0; i < seriesGroups.Count; i++)
if (seriesGroups[i].AxisGroup == AxisGroup.Secondary)
seriesGroups.RemoveAt(i);
Se även
- class ChartSeriesGroupCollection
- namnutrymme Aspose.Words.Drawing.Charts
- hopsättning Aspose.Words