IXlsWorkbooks
COM interface ( getting help with interfaces )

 

interface IXlsWorkbooks : IDispatch
{
  [id(1),propget] HRESULT Count([out, retval]int* nbworkbooks);
  [id(2),propget] HRESULT Item([in]int i, [out, retval]IXlsWorkbook** workbook);
  [id(3)]         HRESULT AddFilepath([in]BSTR filepath);
  [id(4),propput] HRESULT OpenPassword([in]BSTR openpassword);
  [id(5)        ] HRESULT AddFilenameAssociation([in]BSTR filenameExtension, [in]enumExcelTargetVersion target);
  [id(6),propget] HRESULT CSVImportOptions([out, retval]IXlsCSVImportOptions** csvOptions);
  [id(7),propget] HRESULT StyleOptimisation([out, retval] BOOL* bStyleOptimisation);
  [id(7),propput] HRESULT StyleOptimisation([in]BOOL bStyleOptimisation);

}

 

HRESULT Count([out, retval]int* nbworkbooks);
returns the number of opened workbooks.

HRESULT Item([in]int i, [out, retval]IXlsWorkbook** workbook);
returns the i-th workbook.

HRESULT AddFilepath([in]BSTR filepath);
adds the filepath to the list of paths where files are opened from. Useful to open workbooks with relative filenames.

HRESULT OpenPassword([in]BSTR openpassword);
opens the file using the passed password. Applies to XLSX files only. The password may have at most 15 characters (for XLS files) and 255 characters (for XLSX files).

HRESULT AddFilenameAssociation([in]BSTR filenameExtension, [in]enumExcelTargetVersion target);
adds a filename association, for instance a .YYY file can be seen as an Excel 2007 file.

HRESULT CSVImportOptions([out, retval]IXlsCSVImportOptions** csvOptions);
returns the options of CSV importer used to import .CSV files.

HRESULT StyleOptimisation([out, retval] BOOL* bStyleOptimisation);
returns whether or not the style optimisation is enabled, meant to reduce styles in the current file. Default value is true.

HRESULT StyleOptimisation([in]BOOL bStyleOptimisation);
sets whether or not the style optimisation is enabled, meant to reduce styles in the current file. Default value is true.