My MVC application has a simple file download controller action that downloads a file.
Here is the code:
public ActionResult Download(string fileId, string filename)
{
//var fullFilePath = FileService.GetFullPath(fileId); // get the path to file
var fullFilePath = fileId;
return File(fullFilePath, "application/octet-stream", filename);
}
I can download/save files successfully but can’t seem to get Firefox to show the file download progress. All other browsers shows the file download progress.
Does anyone know how to get Mozilla Firefox to show the file download progress?
You need to add
Content-Lengthto the header so the browser can calculate that.