Here is the answer..
iRunnable=new Runnable()
{
@Override
public void run()
{
//do something
}
};
and in the other function
Thread th = new Thread() {
@Override
public void run() {
try {
Thread.sleep(1000*15);
//your code here..
iHandler.postDelayed(iRunnable,20*1000);
}
catch (InterruptedException ie)
{
}
};
th.start();
}