Originally posted by Ko Ko Naing:
Try to put it at the beginning of ur servlet's method, even before the loop so that the header has been set at the very beginning... Hope it helps...
hi again
The wait page still won't display after i put it at top. I try to put in thread but to no avail. It keeps displaying the input page until it redirect to new page.Here is my code
Thread thread = new Thread();
thread.start();
//Include the Wait Page which should be displayed before the transaction starts
res.setHeader("Refresh", "1; URL=https://"+host+"/webjos/CVN/wait.html");
//execute the method that takes time example: insert 10000 records (in a for loop)
thread.stop();
if success
redirect to new page
END