[Solved] NullPointerException Error on simple program [duplicate]
In line 34, as the trace says: window.getChildren().add(dot); either window or dot (or both) are not initialized by then. Hence the null pointer exception. 6 solved NullPointerException Error on simple program [duplicate]