The ExcelWorkbook is used to read Excel spread sheets.
 Those Excel files may be opened for readonly (Readonly workbook) or read / write (Writable Workbook)

Functions

loadWorkbook(data, encoding)

Loads a read only workbook

  • data Can be either a binary (from an attachment for example) or a file path
  • encoding. By default, UTF-8. ISO-8859-1 should be used for ISO latin 1 files.

@return: A readonly workbook
@see: loadWritableWorkbook

createWritableWorkbook(strFileName)

Creates a new writable Workbook

  • strFileName The workbook name

@return: A writable Workbook

loadWritableWorkbook(data, strOutputFileName, encoding)

Read a workbook and creates a writable workbook.
 The filename is just a name. It may not be used as a path to save the Excel sheet.

  • data May be either a binary (for an attachment) or a file path
  • filename The output file name
  • encoding By default, UTF-8. ISO-8859-1 should be used for ISO latin 1 files.

@return: A writable workbook
example:
var workbook = ExcelWorkbook.loadWritableWorkbook(data.custFile.sysData, "test.xls", "ISO-8859-1");

Tags:
Created by Maurice Gasco on 2018/06/07 16:48
     
This wiki is licensed under a Creative Commons 2.0 license
XWiki Enterprise 9.11.5 - Documentation