A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
How to easily write a text file with beautiful format
Joined: Sep 01, 2009
Sep 27, 2010 02:18:14
beginner. I need to write text from database into a beautiful format text file such as a POS slip format.
Can you give me an advice of what I need to know to do things like this.
Thank you very much
Joined: Sep 16, 2005
Oct 05, 2010 10:17:10
One method is to write your output as comma delimited format using
that your user can open in a spreadsheet. The spreadsheet program then organizes your information in the way you want it.
out = new
If this is interactive and you are returning the data as part of a gui response, you can set the headers in your response to automatically activate the application you want your document to use.
response.setHeader("content-disposition", "attachment; filename=\""
+ fileName + "\"");
I agree. Here's the link:
subject: How to easily write a text file with beautiful format
How to store arraylist in xml file
Text file xls to Binary format xls in Java.
Coversion of ResultSet
How to change font of String?
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015