Filter VBA Project while loading a workbook

Filter VBA Project while loading an Excel workbook in Python

Some .xlsm/.xlsb files have an extremely large amount of macros (or very, very long macros). Aspose.Cells for Python via .NET will unconditionally load this (meta) data when opening such workbooks. You may need to control this using LoadDataFilterOptions when you really only need to extract sheet names for a large number of workbooks, thus skipping over such unneeded content. This filter is provided via a new option, LoadDataFilterOptions.VBA.

Sample Code

The following sample code loads a workbook such that only VBA is filtered. A sample file for testing this feature can be downloaded from the following link:

sampleMacroEnabledWorkbook.xlsm