I have the following code nested in a loop reading Excel Rows, it's supposed to read and house the current row's cell values.
IEnumerable<String> textValues = from cell in row.Descendants<Cell>()
//where cell.CellValue != null
select (cell.DataType.HasValue && cell.DataType == CellValues.SharedString
? sharedString.ChildElements[int.Parse(cell.CellValue.InnerText)].InnerText
: cell.CellValue.InnerText
);
Currently it's throwing null Exceptions. I would like to set them to an empty string, rather than skip them, so I still have something I can load into my object.