Simulator Quits

I am trying to write a function that will removeSelf all of the game pieces before starting a new level. If I remove everything accept the quit button it stays with a black screen behind. If I remove all images I get the below in the output and then simulator exits. Is this because all images have been removed?

How can I prevent this?

logout  
[process completed]  

[import]uid: 7197 topic_id: 4896 reply_id: 304896[/import]