Need help for Error: Unable to initialize main class files.Main Caused by: java.lang.NoClassDefFoundError: Stage
keep on showing the error but i cannot solve it please can any body help imidiately with this thanks alot
package files;
import datamodel.TodoData;
import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.stage.Stage;
import java.io.IOException;
public class Main extends Application {
@Override
public void start(Stage primaryStage) throws Exception{
Parent root = FXMLLoader.load(getClass().getResource("mainWindow.fxml"));
primaryStage.setTitle("Todo List");
setUserAgentStylesheet(STYLESHEET_CASPIAN);
primaryStage.setScene(new Scene(root, 900, 700));
primaryStage.show();
}
public static void main(String[] args) {
launch(args);
}
@Override
public void stop() throws Exception {
try {
TodoData.getInstance().storeTodoItems();
} catch (IOException e){
System.out.println(e.getMessage());
}
}
@Override
public void init() throws Exception {
try {
TodoData.getInstance().loadTodoItems();
} catch (IOException e){
System.out.println(e.getMessage());
}
}
}