Problem with stopping my program

Post your code, using code tags.