Hi all,
I am facing this problem,
Caused by: javafx.fxml.LoadException: Error resolving onAction='#MakeNewProject', either the event handler is not in the Namespace or there is an error in the script.
On button click, I face this problem. I write the following code,
@FXML
private void handleButtonAction(ActionEvent event) throws IOException {
if(event.getSource()==btnEnglish)
{
Parent root = FXMLLoader.load(getClass().getResource("/fxml/View_homescreen.fxml"));
Stage addDialogStage=new Stage();
addDialogStage.setTitle("Home Screen");
addDialogStage.initModality(Modality.APPLICATION_MODAL);
Scene scene=new Scene(root);
scene.getStylesheets().add("/styles/Style_selectlanguage.css");
addDialogStage.setScene(scene);
addDialogStage.showAndWait();
}
How do we solve this problem?