aspose file tools*
The moose likes Servlets and the fly likes Change file name without prompt to save Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Change file name without prompt to save" Watch "Change file name without prompt to save" New topic
Author

Change file name without prompt to save

Tom Henricksen
Ranch Hand

Joined: Mar 23, 2004
Posts: 136

When I add the setHeader code to change the name it always
prompts me with a save as box. Is it possible to change
the file name without the prompt to save? If I don't try
to change the file name it opens right into Adobe Acrobat.
As I set the Mime Type to "application/pdf".



Thanks,
Tom
Tom Henricksen
Ranch Hand

Joined: Mar 23, 2004
Posts: 136

I have tried using inline as mentioned this in the is link

http://forum.java.sun.com/thread.jspa?threadID=486951

But the fileName is still the name of the JSP.

Thanks,
Tom
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

Change "attachment" to "inline" and it will open in the browser.


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
Tom Henricksen
Ranch Hand

Joined: Mar 23, 2004
Posts: 136

Ben,
I tried that, as I noted in my second post and the same result. It appears I must have something else messed up.
Thanks,
Tom
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Change file name without prompt to save