If you're using .NET then the DrawToWeb method is overloaded and you can specify the filename. This isn't the case in the Classic ASP/VBScript world. The following is the only way I managed to do it:
...
...
Response.ContentType = "application/pdf"
Response.AddHeader "content-disposition", "inline;filename=test.pdf"
ByteArray = DOC.Draw
Response.BinaryWrite ByteArray
...
...
Hope this helps someone.
Forcing filename of PDF for DrawToWeb
Re: Forcing filename of PDF for DrawToWeb
Support · Apr 2, 2014Hello,
Currently it is not possible to specify the file name using DrawToWeb method of the Document object. The above code can be used as a workaround to force the file name when the PDF is saved from the browser menu (File > “Save Page As”).
Thanks,
ceTe Software Support Team.