Hi nnara530. I executed your code and it works very well. But when I insert it into a loop, I notice that the progress bar is shown when the entire process is finished and I need it to be shown as it runs. Could you help me with this?

Yeah, this is an issue in the SC. Buffering. even though you place this code in between, for some reason sc is not showing the output. This could be their bug.

The following might help but i have not tested. Place the below methods after your scrollbar display method in your loop. The below will try to flush out the screen. If you are lucky it will output immediately to the screen.

echo str_pad(’’,4096)."
";
ob_flush();
flush();