We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Save XLS file in compatbility mode

Thread ID:

Created:

Updated:

Platform:

Replies:

118898 Apr 21,2015 11:34 AM Apr 23,2015 09:59 AM Windows Forms 1
loading
Tags: XlsIO
jb
Asked On April 21, 2015 11:34 AM

Am using version 8.404.0.10 of the library.

I want to create and save .xls file and open them with excel 2007 +. Currently if i do that then i get a warning stating the file extenion/format is different and if i click yes, the file opens.

However i can create an xls file in office 2010 and save it in compatiobility mode and open it without any warning.



Vikas Sekar [Syncfusion]
Replied On April 23, 2015 09:59 AM

Hi,

The warning message you have shared us is due to invalid version. Please follow the below code snippets to save the file in respective version.

Code Snippet:

//To Save file in .xls Format

workbook.Version = ExcelVersion.Excel97to2003;

workbook.SaveAs("[FileName].xls");

//To Save file in .xlsx Format

workbook.Version = ExcelVersion.Excel2007;

workbook.SaveAs("[FileName].xlsx");

Please lets us know if you need any clarification.

Regards,

Vikas


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;