If the $crc of a single file takes too long then you have only the alternative given by starbucks_mafia.

However, if you find the delay of $crc'ing one file acceptable, you could use a timer instead of a while loop. Make a separate alias for the loop contents, /set the while index in a %var and use if instead of while, then, when you need to loop, do a /timer 1 0 /aliasname.

This timer will trigger immediately after your previous loop executes AND after handling all other mIRC stuff that was received dureing the $crc. Your mIRC will not timeout then, ofcourse the program will still seem slow since it updates text and editbox contents only between calls to $crc...