Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package sample;
- import javafx.application.Application;
- import javafx.fxml.FXMLLoader;
- import javafx.scene.Parent;
- import javafx.scene.Scene;
- import javafx.stage.Stage;
- public class Main extends Application {
- @Override
- public void start(Stage primaryStage) throws Exception {
- FXMLLoader loader = new FXMLLoader(Main.class.getResource("/sample.fxml"));
- Parent content = loader.load();
- primaryStage.setTitle("Hello World");
- primaryStage.setScene(new Scene(content, 700, 500));
- primaryStage.show();
- }
- public static void main(String[] args) {
- Application.launch(args);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement