Progress window not responding

  • Thread starter Thread starter Mitchell Vincent
  • Start date Start date
M

Mitchell Vincent

I have a progess window with a label and progressbar that get updated
once per iteration of a for next loop. Everything works perfect (after I
call the Refresh members of any control I change in the loop,. like the
label), until the progress window loses focus and gains it back. If I
shift focus from the progress window back to the main window and then
back to the progress window all the controls stop updating but I see
through a debug message that the loop is still going just fine. If I do
the focu shift once more then the window title get the lovely "not
responding" tag..

How might I prevent this? The loop does call a function from a DLL that
can take some time to comlete and does block, but never more than .25
seconds per iteration.

I tried doing the processing in an async delegate but it always hung for
some reason when I instantiated the DLL (activex) object.

Thanks for any tips or pointers!
 
Back
Top