IExcel Reader Interface
Provide methods for reading an excel file.
Example
C#
var reader = Readers.GetExcelReader();
using(reader.Open(documentApi.OpenRead(ctx.Input.DocumentAttribute)))
{
var workSheetReader = reader.GetSheet(0);
var rowCount = workSheetReader.RowCount;
var columnCount = workSheetReader.ColumnCount;
for (int row = 0; row < rowCount; row++) {
for (int col = 0; col < columnCount; col++) {
var value = workSheetReader.Read<string>(row, col);
}
}
}Definition
Namespace: Casewhere.Runtime.IO
Assembly: Casewhere.Runtime.IO (in Casewhere.Runtime.IO.dll) Version: 1.0.0.0 (1.0.0.0)
Assembly: Casewhere.Runtime.IO (in Casewhere.Runtime.IO.dll) Version: 1.0.0.0 (1.0.0.0)
C#
public interface IExcelReader : IDisposable,
IIOApi- Implements
- IIOApi, IDisposable
Methods
| Close | Close the connection to an excel file. |
| Dispose | Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. (Inherited from IDisposable) |
| GetSheet | Get a sheet by its index. |
| Open(Byte) | Connect to the byte array of an excel file to prepare for reading. |
| Open(Stream) | Connect to the file stream to prepare for reading. |