• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

open file-download window from servlet

 
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
This is the scenario I'm trying to achieve:
- Display html page with a button or href "download csv file"
- the user clicks
- the file-download pop-up window should appear,so the user
can save the file to any location

This is how far I get:
- when the user clicks a servlet gets activated
- Servlet:
- creates the csv file and write it to disk
- now I want the servlet to do something so that the
file-download window opens
- I've tried with forward the request to the url (which only displays the content in the browser)
- I write to HttpServletResponse it opens the file in excel which I don't want

Any ideas ?
Thanks in advance
Per
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic