lundi 29 février 2016

Unable to download Excel file in iOS

How can you trigger a download in ASP.NET (C#) of an Excel document on an iOS device. All other devices just download the export right now. But iOS keeps giving the following response:

Screenshot of iOS

Right now I'm using the following code:

    [HttpGet]
    public ActionResult ExportList(string ds)
    {
        //Generating the Excel file
        ...

        //return the file
        var fileName = Config.GetFileName("xlsx");
        return File(tempFile, MimeMapping.GetMimeMapping(fileName), fileName);
    }




Aucun commentaire:

Enregistrer un commentaire