Results 1 to 7 of 7
- 07-10-2007, 07:34 PM #1
Member
- Join Date
- Jul 2007
- Posts
- 1
- Rep Power
- 0
writing to a excel file from java program
Hi,
I want to create and write to a excel file from a java program. I found a tutorial online and wrote a java file as under:
But when I compile this file, I get errors telling that package jxl does not exists and so on. Do I need to download it ? I am really new to it but I need to do the job. Please give some ideas.Java Code:import java.io.File; import java.util.Date; import jxl.*; import jxl.write.*; public class jExcel{ WriteableWorkbok workbook = Workbok.createWorkbook(new File("output.xls")); public static void main(String args[]){ WriteableSheet sheet = workbook.createSheet("First Sheett",0); Label label = new Label(0,2,"A label record"); sheet.addCell(label); Number number = new Number(3,4,3.1459); sheet.addCell(number); workbook.write(); workbook.close(); } }
Thanks,
PriyankaLast edited by JavaBean; 07-10-2007 at 08:18 PM. Reason: Code is placed inside [code] tag.
- 07-10-2007, 08:05 PM #2
Member
- Join Date
- Jul 2007
- Posts
- 51
- Rep Power
- 0
You can download from here
SourceForge.net: Files
- 03-30-2011, 06:53 PM #3
Member
- Join Date
- Mar 2011
- Posts
- 1
- Rep Power
- 0
When I follow the link, and I select JexcelAPI it shows me several different versions.
Do I just download the newest one?
-
I'd just like to point out that any package NOT starting with one of these:
java.
javax.
is a custom/community package i.e. not standard and thats why you will need to download them yourself
also its usually best to download the latest and most stable version. look for user feedback and if the latest version doesnt have any serious bugs then you should use that one.
- 03-31-2011, 11:42 AM #5
Member
- Join Date
- Mar 2011
- Posts
- 16
- Rep Power
- 0
For creating .xls files from java. One of the good API is jXl API.
You can find more details from following URL
JExcelApi
- 03-15-2012, 03:56 PM #6
Member
- Join Date
- Mar 2012
- Posts
- 1
- Rep Power
- 0
Re: writing to a excel file from java program
Can someone please tell what is the equivalent for Label in Apache Poi???
Thanks,
Basavaraj
- 03-15-2012, 04:29 PM #7
Moderator
- Join Date
- Apr 2009
- Posts
- 10,481
- Rep Power
- 16
Similar Threads
-
Reading data from Micrsoft excel and writing to notepad
By abhishek.jain in forum New To JavaReplies: 4Last Post: 01-29-2009, 08:12 AM -
How to get the last modified date of a file from a java program
By Java Tip in forum java.ioReplies: 0Last Post: 04-04-2008, 02:45 PM -
Help needed writing a program...
By Francis in forum New To JavaReplies: 2Last Post: 11-22-2007, 02:03 PM -
writing to a file
By bugger in forum New To JavaReplies: 1Last Post: 11-11-2007, 02:49 AM -
Poblem in Compiling a c++ file from a java program...
By Amit Kr. Mishra in forum New To JavaReplies: 0Last Post: 11-06-2007, 10:41 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks