开发者

Getting started with Java using Eclipse

I just heard of library for reading/writing excel files without COM, so I figured I'd go check it out.

I downloaded jexcelapi_2_6_12.zip from this page http://sourceforge.net/projects/jexcelapi/files/ but I have 开发者_C百科no idea how to open it in Eclipse.

I know it's a silly question, but I'm sure it's not the first time someone's asked it, how do I open this in Eclipse in Windows, compile, run and debug it?


Primarily what you need from that zip is the jar which contains the library. You'll still need to actually write a Java app that uses it.

So what you need to do is:

  1. Unzip the file you downloaded
  2. create a new java project
  3. add a lib directory to the project
  4. copy jxl.jar from the zip into your projects lib directory
  5. right click on the jar in eclipse and select "Build Path>Add to build path"

The classes in the library are now available to your project Next create a new java file in your projects source folder and start coding.


Extract the zip file somewhere, put the jar file in your project's directory somewhere (e.g. under a lib directory) and then right-click on it and select "Add to build path" or something similar.

It's not runnable on its own though - you'll need to write some code in order to debug.

If you want to debug into the source code of the library itself, you'll need to tell Eclipse where the source is - but that's unlikely to be necessary.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜