You can use BINDEVENT() to bind to Windows messages to catch your application activation and refresh the form. The sample code that comes with VFP9 shows how to bind to Windows messages.
>I have a very intensive 30+ minutes process that downloads five large tables (a few over 500K rows) via ADO then drops them into Excel's pivotcache object. In order to reveal the status to the end user, I created a form that contains a grid that is used to show the status such that task 1 (download table 1) is complete.
>
>I am running the process now and when I switched to another app (such as the UT) and come back to my program the form appears but it is all blank. I can no longer see the grid that is attached to the form at all.
>
>I suppose I need to call a form refresh or paint but how can I do that when all the processing cycles are involved in an intensive process? Can I do something like a click event on the form to refresh itself or will that be ignored when the program is running since all resrouces are assigned to the table download? Is there a way around this sitution? If not, all my work to create a form with a grid to show the status is probably a waste of time...
--sb--