Problem: Program crashes with NSArray's out of bounds exception Solution: Unlike List objects, which returned nil if you ask for an object which is beyond the List's range, NSArray raises an exception. Here's an example of code that will bite you: int i = 0; id g = [list objectAt:i++]; while (g!=nil) { ... g = [list objectAt:i++]; // used to return NIL // now it's out of bounds error! } New code checks size first, and iterates based on count: NSEnumerator *objectEnumerator; id nextObject; objectEnumerator = [array objectEnumerator]; while(nextObject = [objectEnumerator nextObject]) { .... } Problem: Program looses key window status and drawing is messed up Solution: Check and DOUBLE_CHECK that you have matched all disableFlushWindows with a matching enableFlushWindow!! |