Register now or log in to join your professional community.
lets asume you have a variable of thread in java say it "ThreaD"
ThreaD.start();
right after that write
While(Thread/isAlive());
this will end up in a lopp that rung untill thread is running
refference http://docs.oracle.com/javase/7/docs/api/java/lang/Thread.html#isAlive()