Maxscript suspends during long operations

Hi guys - I’m new, although have been lurking for a while :cool:

I have a maxscript problem I’d like some help with.
I’ve set up a script that generates point lighting samples from an environment set up with radiosity. It works great, however, the calculations take ages (4 hours or so) on large arrays and I’d like to add a progress bar so that artists don’t think Max has crashed.
The problem is that after 500 or so operations in a loop, Max seems to enter a suspend mode where the script is just processing but nothing is output to the listener or output to the screen - if I add a progress bar, it simply doesn’t update past a certain point until that particular loop has completed.

Is there anyway to turn this mode off, or keep the progress bar from suspending? I’m prepared to accept some performance loss since the times I’m dealing with require the script to be run offline.

Thanks everyone.

I posted about a similar issue a few months back:
http://tech-artists.org/forum/showthread.php?2483-Refreshing-Redrawing-Controls-During-MAXScript-Execution&p=15136#post15136

In the end, I was able to force the redraw of the UI of the tool in question by running the follow function (placing it at key points in my code that required a UI redraw).

windows.processPostedMessages()