Results 1 to 5 of 5
  1. #1
    Join Date
    Jun 2008
    Posts
    54
    Rep Power
    0

    Default cannot find imports..

    hey... i finally solved my excel problem... but just kind of... i have to do it with a package, which i managed to get, but my problem ist now, that my programm is not finding the path or sth like this, this is my code:

    import java.io.File;

    import jexcelapi.src.jxl.Cell;
    import jexcelapi.src.jxl.Sheet;
    import jexcelapi.src.jxl.Workbook;
    import jexcelapi.src.jxl.read.biff.*;

    public class Excel
    {
    public static void main(String[] args)
    {
    Workbook workbook = Workbook.getWorkbook(new File("//Volumes//ws.xls"));

    Sheet sheet = workbook.getSheet(0);

    Cell a1 = sheet.getCell(0,0);
    Cell b2 = sheet.getCell(1,1);
    Cell c2 = sheet.getCell(2,1);

    String stringa1 = a1.getContents();
    String stringb2 = b2.getContents();
    String stringc2 = c2.getContents();
    }
    }


    and the problem is, that it is not accepting my get.Workbook, it is always telling me that i am referring to a not existing BiffException, but apparently it is in my package and if i am writing import jexcelapi.src.jxl.read.biff.BiffException; instead of import jexcelapi.src.jxl.read.biff.*; it is telling me the folowing error mistake:

    The archive: /neu/E:/usr/local/woodstock/jexcelapi/2_4_3/jxl.jar which is referenced by the classpath does not exist

    i really have no idea what to do with it, so can anyone explain it to me...

    little_polarbear

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,318
    Rep Power
    25

    Default

    it is telling me the folowing error mistake:
    Please copy and paste the full error message without editting it.

    What program is the 'it' you refer to above?

  3. #3
    Join Date
    Jun 2008
    Posts
    54
    Rep Power
    0

    Default

    ok, the programm is my eclipse, i am using the newest version, the error message ist what i wrote above without editing, an extra window is occuring and i cannot copy out of it... really strange bur it is saying the exact words which i wrote above...

    Launching Excel has encountered a problem

    The archive: /neu/E:/usr/local/woodstock/jexcelapi/2_4_3/jxl.jar which is referenced by the classpath does not exist

    these are the exact words... i don*t know how to handle with it and either what it means and also not if there is actually maybe a mistake in the package which i got...

    little_polarbear

  4. #4
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,318
    Rep Power
    25

    Default

    Sorry, I don't know anything about using eclipse.
    Good luck.

  5. #5
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

    Default

    Did you attach the external jar file(jxl.jar) to your project. I'm a NetBeans user, so I don't know how to attach an external jar files there. But seems to me that you don't have attach it.

Similar Threads

  1. Imports broken in JSP; HTTP Status 500-
    By Aerinai in forum JavaServer Pages (JSP) and JSTL
    Replies: 0
    Last Post: 06-13-2008, 10:27 PM
  2. How to use Static Imports
    By Java Tip in forum java.lang
    Replies: 0
    Last Post: 04-17-2008, 07:37 PM
  3. Static imports (Java 5 and above)
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 12-17-2007, 10:02 AM
  4. Organising Imports - Eclipse
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 11-15-2007, 05:15 PM
  5. My JSP can't find the servlet
    By gabriel in forum JavaServer Pages (JSP) and JSTL
    Replies: 1
    Last Post: 07-29-2007, 09:01 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •