Documentation
¶
Overview ¶
Package xls reads legacy Microsoft Excel .xls (BIFF8) workbooks. It exposes the sheet names of a workbook and streams each sheet's rows without loading the whole sheet into memory.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cell ¶
type Cell struct {
// Column is the spreadsheet-style column label, e.g. "A", "B", "AA".
Column string
Type CellType
Value any
}
Cell is a single spreadsheet cell.
type File ¶
type File struct {
// contains filtered or unexported fields
}
File is an opened .xls workbook. Call Close when done with it.
func OpenFile ¶
OpenFile opens the .xls workbook at path. The returned File must be closed with Close.
func OpenReader ¶
OpenReader opens a .xls workbook from r. Unlike OpenFile, the caller retains ownership of r and Close will not close it.
func (*File) Close ¶
Close releases resources associated with the File. If the File was obtained with OpenReader, Close is a no-op.
func (*File) ReadRows ¶
ReadRows streams the rows of the sheet named sheetName in order. The returned channel is closed once all rows have been sent, after an error, or immediately if no sheet with that name exists.
func (*File) SheetNames ¶
SheetNames returns the names of the workbook's visible worksheets, in the order they appear in Excel.