Scheduling a java program using another java program -


as part of automation want schedule java program after 12 hours using java program running. client machine windows. can't when first script start , once ends, has schedule second script should start after 12 hours. suggestions on how it?

i use java.util.timer.schedule(timertask task, long delay). task schedule can invoke second java program appropriately. example:

public void scheduletask() {     timer timer = new timer();     timer.schedule(new timertask() {         public void run() {             try {                 runtime.getruntime().exec("java secondprog.class &");             } catch (ioexception e) {                 // todo auto-generated catch block                 e.printstacktrace();             }         }     }, 12*1000*60*60);  } 

Comments

Popular posts from this blog

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -

java - JavaFX 2 slider labelFormatter not being used -