We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose.Cells Xls to XlsB conversion

Hi,

How can i decide weather the file .xls needs to get converted to xlsb or xlsm or xlsx.
i want to convert old formats of office excel to new formats, Is there any properties from which i can decide for XLSB format
like macros has .HasMacro property is there any property to detect xlsb

Hi,

Thanks for your posting and using Aspose.Cells.

You can always convert xls file to xlsb format no matter it has macros or not.

For other formats, please check if your xls file has macros. If it does not have macros, then convert it to xlsx format and if it has macros then convert it to xlsm format.

You can check if the workbook has macros or not via the Workbook.HasMacro property.

Also you can check the file format of the workbook if it is xls, xlsm, xlsb or xlsx using its Workbook.FileFormat property.

You can also detect the file format of any excel file using FileFormatUtil.DetectFileFormat() method as described in this article.

( https://docs.aspose.com/cells/net/how-to-detect-a-file-format-and-check-if-the-file-is-encrypted )

Thank you for prompt reply,

But i want to know for sure what property dose xls file shows for it to be converted to xlsb rather than any other format. I know that i can detect macro from HasMacro property but is there any property like IsBinary ao something
Thank you.

Hi,

Thanks for your posting and considering Aspose.Cells.

Xls is an older format which is now divided into three newer formats.

1) Xlsx
2) Xlsm
3) Xlsb

You can say, Xls contains all of the above formats. Therefore you do not need any property to determine if it should be converted to Xlsb or not. You can always convert Xls file to Xlsb whether it has macros or not.

Please note, Xlsb is a binary format of Xls and Xlsm file. It is used when you want to decrease the file size of your resultant excel file.