Why is XSLX file getting downloaded as XLS in IE only? - excel

We created an XLSX file using Excel 2013 (packaged it within the WAR file) and gave a hyperlink to this file for users to download it. Application is hosted in Tomcat server.
Users using IE 11, when downloading this file, it is getting downloaded & saved as .XLS extension.
Users using Chrome, when downloading this file,it is XLSX extension.
It is a direct download hyperlink to the file. Why is it behaving differently in both browsers ? What could be the root cause of this issue ?

We were having the same problem - .xlsx files were only downloading as .xls and causing annoying warnings for the users when they tried to open the file, because it was opening the file as an .xls so the contents did not match the format, but it worked fine in Chrome.
We found that had two entries for the .xlsx MIME Type in IIS:
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
and
application/vnd.ms-excel
When we removed the second one (vnd.ms-excel), the file downloaded appropriately and we were able to open the document directly without the error message.
It appears that the second mime-type entry caused Internet Explorer to treat all excel files as .xlsx. Now, why it does that, I'd love to know.
Hope this helps.

Related

Netsuite how do I open a file in the browser (Doc, excel) without downloading

Files which are uploaded onto the system will only show in a new browser if it is an image or PDF. If it's any other file format it will automatically download the file. Is there a way around this?
I have tried using SuiteScript to access the file and open it in a new browser but, it will download it once opened in a new browser.

Links in excel stop working when file is saved

I was emailed an excel file with a number of links to install direct printer queues. If I open the excel attachment directly from the email the links work, but if I save the attachment to my desktop the links no longer work and I get an error “Cannot open the specified file”.
If I copy the link into Windows explorer, it works fine. Is there a way to ensure the links still work from excel when the file is saved in a shared location so anyone with access to the file can click on the links without having to copy the link into Windows explorer?

Launch an add-in systematically when opening a file

I want to make an Excel Online file, then post its link or embed it in my website. Clicking on that will open the file in Excel Online. Moreover, I want certain Excel add-ins to be installed and even launched automatically.
Does anyone know if it is possible?
If it's impossible with Excel Online, is it possible for a normal .xlsx file (I will make it, and opening it in Windows systematically leads to install an add-in and even launch it)?
If you're looking to automatically open a task pane add-in when the Excel file is opened, check out this article in the documentation: https://dev.office.com/docs/add-ins/design/automatically-open-a-task-pane-with-a-document?product=excel. The Office OOXML EmbedAddin sample provides an example of implementing the autoopen functionality that's described in the article.
Along with Kim's answer to automatic opening of a task pane add-in, you can using OneDrive to handle opening a file in Excel Online using Microsoft Graph.
You're start by uploading you're .xlsx file to OneDrive using an Upload Session. Once you're file is on OneDrive, you can retrieve it's meta-data for the DriveItem. Included in this meta-data will be a webUrl property. This is a URL that, when navigated too, will open your file using Excel Online.

.dot document is being downloaded as .doc in iis

I have a web app running on IIS 7 and I have a hyperlink to a .dot (Microsoft Word template) document (mytemplate.dot).
However, when the users (or myself) try downloading it, they got the file as a Word normal document (mytemplate.doc).
I've tried to modified the MIME type of .dot file from application/msword to application/dot; and also have tried removing the MIME type completely, but the results are the same.
When does it become a .doc file, when it's downloaded (transformed in the download process) or is it just prompting you to save it as a .doc file (which is standard behavior for templates).

SharePoint document library: Fail to open xlsx in Excel 2003 (with compatibility pack)

My company is using WSS 3.0 to host a document library storing (mostly) Office 2007 format documents. Company PCs have either Office 2003 (with the 2007 compatibility pack) or Office 2007 installed.
We didn't have any problem getting docx to work, but xlsx documents don't open properly when we use the SharePoint document edit options. The file opens in excel, but displays unformatted mess (close to the notepad representation). The actual files are fine, downloading the xlsx file (using the send to -> download option) allows the file to be opened. It is only when we use SharePoints 'Edit in Microsoft Excel' that we get an issue.
I think that the issue is excel (2003) trying to open the xlsx file as if it were and xls file, and being unable to represent the zipped contents. Has anyone seen this issue before?
EDIT: I've noticed that when the document is opened with explorer, it actually opens through the Microsoft open XML coverter. Clearly, SharePoint isn't using it, is there a fix that works round this?
UPDATE: I have done a bit more research, as added in the comment below this issue replicates across all machines on our network which use office 2003 and XLSX files from SharePoint. I have confirmed that using excel to open xlsx files in explorer (without the converter) results in the same issue as when they are opened from SharePoint. I think i need a way to tell SharePoint/IE (whatever actually handles the office interaction, URLMON/HLink?) that the proper file assosciation for XLSX isn't excel.exe.
Are you able to test this on another computer? Might be related to a registry entry and/or other software causing it (because you did not had problems with word). The ideal test scenario would be a brand new OS Install with only Office 2003 and the compatibility pack.

Resources