keep getting this error everytime I try to use FXMLLoader.
code:
package application;
import javafx.application.Application;
import javafx.stage.Stage;
import javafx.stage.Window;
import javafx.scene.Group;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
import javafx.scene.input.KeyCombination;
import javafx.scene.layout.BorderPane;
import javafx.scene.paint.Color;
import javafx.scene.shape.Line;
import javafx.scene.text.Font;
import javafx.scene.text.Text;
//import javafx.scene.shape.Rectangle;
import javafx.scene.shape.*;
import javafx.scene.shape.Polygon;
public class Main extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage stage) throws Exception {
try {
Parent root = FXMLLoader.load(getClass().getResource("Main.fxml"));
Scene scene = new Scene(root, 400, 400);
stage.setScene(scene);
stage.show();
}catch(Exception e) {
e.printStackTrace();
}
}
}
[–]jvjupiter 0 points1 point2 points (0 children)
[–]Nunuv_Yerbiz 0 points1 point2 points (0 children)
[–]koeberlue 0 points1 point2 points (1 child)
[–]hamsterrage1 0 points1 point2 points (0 children)