public SharedStrings(string path) { this.path = path; data = new XElementData(XDocument.Load(path).Root); data.RemoveAttribute("count"); // optional values - will be recalculated data.RemoveAttribute("uniqueCount"); // optional values - will be recalculated ReadContents(); }
// existing rows constructor private Row(XElementData data, ISheetData sheetData) { this.Data = data; this.sheetData = sheetData; Index = int.Parse(data["r"], NumberFormatInfo.InvariantInfo); data.RemoveAttribute("spans"); // clear spans attribute, will be recalculated }