I have a method looking like this:
public FileContentResult DownloadFile()
{
// Lots of code
fileData = myWebService.GetFileBytes();
return File(fileData, "application/zip", "myZippedFile.zip");
}
This method is working fine in Firefox, Chrome and Internet Explorer < 11 in which nothing at all happens. I haven't been able to find anything related to my issue after googling for quite a while so now I turn to you.
Has anyone encountered this problem and found a solution?
Edit I've recently started to delve deeper into the code and actually looked at the JavaScript calling this method, which looks like this:
window.navigator.msSaveBlob(blob, filename);
This line is not called for IE11 as my browser check fails to recognize that this is actually Internet Explorer and thus starts to execute code that only works for Firefox and Chrome.