Java code to run data from acrobat distiller -


i writing program should select .txt files selected directory , print them using acrobat distiller. @ present, can select , open files first file printed , error: system.out.println("completed") whitout completing of other print out.

import java.io.file; import java.io.ioexception;   public class acrobat {      public static void main(string[] args) {          file foldertotalcountletters = new file("c:\\users\\jayraj\\workspace\\auto\\proof\\us\\letter\\07-01-2013");         file[] listoffilestotalcountletters = foldertotalcountletters.listfiles();          string totalcountletters;          try{              (int itotalcount = 0; itotalcount < listoffilestotalcountletters.length; itotalcount++) {                 if (listoffilestotalcountletters[itotalcount].isfile()) {                      totalcountletters = listoffilestotalcountletters[itotalcount].getname();                      system.out.println(totalcountletters);                      runtime runtime = runtime.getruntime();                     process process = runtime.exec("acrodist");                 }             }         } catch (exception e25) {                 e25.printstacktrace();             }      }  } 

this more detailed content of error.

proof_us_30189650_06-29-13_mail_recordcount_56.txt.txt java.io.ioexception: cannot run program "acrodist.exe": createprocess error=2, system cannot find file specified     @ java.lang.processbuilder.start(unknown source)     @ java.lang.runtime.exec(unknown source)     @ java.lang.runtime.exec(unknown source)     @ java.lang.runtime.exec(unknown source)     @ acrobat.main(acrobat.java:24) caused by: java.io.ioexception: createprocess error=2, system cannot find file specified     @ java.lang.processimpl.create(native method)     @ java.lang.processimpl.<init>(unknown source)     @ java.lang.processimpl.start(unknown source)     ... 5 more 

i have no idea selected files printed out.


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -