Java isn't getting the file in the source code when compiled
问题 Recently I have an issue with Java. I've tried some things I found on the web but they haven't worked, so I need help. I have a Java project in Eclipse. My main class is in src/programCode/UI_Main2.java . In that .java I try to access to a file in src/files/File.file And this is when the things fo weird. If I use /src/files/File.file it gives me NoSuchFileException . If I use src/files/File.file it works in Eclipse but when I compile it to a executable .jar it gives me NoSuchFileException .