|
I have a large XLS file with one worksheet containing 8 columns and 18216 rows.
When using the ExcelDataReader library I encountered the problem that unique strings are missing starting from row with index 11888.
I use the library as described on this website:
1. ExcelReaderFactory.CreateBinaryReader(stream);
2. DataSet result = excelReader.AsDataSet();
3. Take out table[0] and start iterating over all rows and print column values of each row.
I debugged it a bit and pinpointed the problem has to be in the algorithm of the method: XlsBiffSST:ReadStrings
because the method: XlsBiffSST:GetString returned string.empty due to the fact that the index was out of range of the m_strings array.
Due to the fact that my knowledge of this lib is very low and the ReadStrings method is pretty complex I would like to ask if someone can take a look at this problem an come up with a fix.
public string GetString(uint SSTIndex)
{
if (SSTIndex < m_strings.Count)
return m_strings[(int)SSTIndex];
return string.Empty;
}
|