Hi I am stuck with following code. I would like to get files from folder but when I export project to jar file it wont work any idea?
 public String getXSDfilenames() {
        String filenames= "";
        try {
            File currDir = new File(".");
            String path = currDir.getAbsolutePath();
            path = path.substring(0, path.length()-1);
             File file = new File(path+"src\\schemaFiles");     
            String[] files = file.list(new FilenameFilter() {
                public boolean accept(File dir, String name) {
                    return name.endsWith(".xsd");
                }
            });
            if (file.exists()) {
                for (int i = 0; i < files.length; i++) {
                    System.out.println(path+"src\\schemaFiles\\"+files[i]);
                filenames = filenames + files[i] + newline;
                }
            } else {
                System.out.println("No schema files founded in default folder!");
            }
        }
         catch (Throwable e1) {
        System.out.println(e1);
        }
        return filenames;
    }
}
 
     
    