public OpenXmlElement GetOrCreateShapeProperties() { DataPoint dataPoint = this.series.Element.Elements <DataPoint>().Where(dp => dp.Index?.Val <= this.valueIndex).LastOrDefault(); if (!(dataPoint?.Index?.Val?.HasValue ?? false) || dataPoint.Index.Val != this.valueIndex) { dataPoint = this.series.Element.InsertAfter( new DataPoint() { Index = new Index() { Val = this.valueIndex }, Bubble3D = new Bubble3D() { Val = false } }, dataPoint ); } return(dataPoint.ChartShapeProperties ?? dataPoint.AppendChild(new ChartShapeProperties())); }