1

I'm trying to open PDF file in browser using Generic Handler (ASP.NET MVC). When I open it, window title is the name of this Handler, written in its class. If I try to download PDF using its own download button, the type of downloading file is PDF and name - file's name; I have added headers in Handler's script ("Content-Type" and "Content-Disposition": "filename=\"fileName.pdf\"").

I tried to write context.Response.AddHeader("Title", "fileName.pdf");, but it does not work too.

How can I change window title/name, viewing PDF using Generic Handler? Thanks..

GuRAm
  • 758
  • 1
  • 7
  • 22

1 Answers1

0

Tab/window title is for pdf files is taken from 'title' property of pdf file, You may find some hint here

michas84
  • 177
  • 3
  • 11