There is a command in Visual Basic called "DoEvents" this allows the system to process normally while you are waiting in a loop. I need Maya to do the same thing.
Consider this code.
Code:
// Wait for an object to be select. string $allObjects[]; string $obj; select -cl; $allObjects = `ls -sl -o`; while (size($allObjects) = 0) { //Wait until we get something in our list $allObjects = `ls -sl -o`; } print ($allObjects[1] + "\n");
Thanks,
Enivob