Search:

Type: Posts; User: Junky

Search: Search took 0.09 seconds.

  1. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    Use the command line to create the jar file. Search for a jar tutorial. Or search for how your IDE can be configured to create the jar file.
  2. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    Did you create a manifest file?
    Did the manifest file have the correct information?
    Did you include the manifest file in the jar file?
  3. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    Try running it from the command prompt or wrap all your files up in a jar file.
  4. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    How are you launching the application?
  5. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    That is not going to work because that is not where the file is. Where in my previous reply did I suggest doing that?
  6. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    You can either place the file in the location that the JVM is looking or you can include the full path.

    String filename = "C:/full/path/to/file/items.txt";
  7. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    By the way you can just use a JFileChooser.
  8. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    System.out.println(System.getProperty("user.dir"));

    Add that as the first line in your program and it will display where it is looking for the file.
  9. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    File not found is self evident. Your program cannot find a file called items.txt in the current working directory. Where is it?
  10. Replies
    21
    Views
    2,081

    Re: Can't find file (not sure the error)

    Which is line 33?
    Where is the rest of your code? If it is too long then create a SSCCE (google it).
    In the catch statement put e.printStackTrace() as this will give you more information than...
Results 1 to 10 of 10