Originally posted by Roger Chung-Wee: A top-level class cannot be declared static - this is standard Java.