I created a table using the Open XML SDK in C # and successfully completed two sheets.
When I try to fill in the third, I get an error message "Unreadable content" when I open the completed document, and it seems to occur when I try to fill in more than 25 cells in the row on the third.
I use the same piece of code that worked successfully elsewhere in the document:
string[] headers2 = { "Reference", "Raised", "Priority", "Affected", "Linked incidents", "Points", "SLA", "Stopped", "Target" }; // remaining headers are month/years created on the fly string[] headerCells = { "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "AA", "AB", "AC", "AD", "AE", "AF", "AG", "AH" }; ... // headers // once we've finished the presets, the month/year pairs take over cellNo = (uint)0; foreach (string h in headers2) { cell = InsertCellInWorksheet(headerCells[cellNo++], 2, worksheetPart); cell.CellValue = new CellValue(h); cell.DataType = new EnumValue<CellValues>(CellValues.String); } string[] monthYears = GetData_month_years(currentReportingPeriod - 1); for (int j = 0; j < monthYears.Count(); j++) { cell = InsertCellInWorksheet(headerCells[cellNo++], 2, worksheetPart); cell.CellValue = new CellValue(monthYears[j].ToString()); cell.DataType = new EnumValue<CellValues>(CellValues.String); }
Single filled cells: A and AA through AH.
I am right in thinking that I am pushing some kind of limit, and if so, how can it reset?
I saw several reports of an unreadable content error, and I looked through the documentation, but so far I have not been able to find anything that is applicable.
Help will be appreciated!
thanks