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

Free Support Forum - aspose.com

Opening a workbook with the LoadOptions of LoadDataOnly=true brings in styles

I am attempting to open a workbook using the following command:

Workbook workbook = new Workbook(filename, new LoadOptions() {LoadDataOnly = true});

I only want the data, no styles or other formatting. In the file, background shading was placed on several cells. The formatting is still there when I save as a new name.

I just tried it in the Aspose.Cells.8.6 DLL with the same results.

What am I doing incorrectly?


Thanks for your query.

Well, there is no such option available in the Aspose.Cells APIs set now. You may save to text format e.g CSV, Tab delimited or txt if you want the formatting should not be retained. Also, we do have only LoadOptions.LoadDataAndFormatting option. When you set it to true, it would only load data, formulas and formatting from the file, so, other contents
and settings all are discarded, e.g shapes, validation, conditional
formatting, PivotTables are not loaded anymore.

Thank you.