I'm trying run a report and I'm very sure that the file is there but still getting this message I try changing directory outside the package inside everywhere. I'm using a Mac(ios).
This the error
java.io.FileNotFoundException: \Users\jeffyarias\NetBeansProjects\LOAN\src\reporte\cliente.jrxml (No such file or directory) BUILD SUCCESSFUL (total time: 10 seconds)
.
try{
Class.forName("org.gjt.mm.mysql.Driver");
Connection con = DriverManager.getConnection("jdbc:mysql://127.0.0.1/Loan", "root", null);
String reportpath="\\Users\\jeffyarias\\NetBeansProjects\\LOAN\\src\\reporte\\cliente.jrxml";
JasperReport jr= JasperCompileManager.compileReport(reportpath);
JasperPrint jp= JasperFillManager.fillReport(jr, null, con);
JasperViewer.viewReport(jp);
con.close();
}
catch (Exception ex){
System.out.println(ex.getMessage());
}