TabPane tabpaneSubs = new TabPane();
stackPane.getChildren().add(tabpaneSubs);
button.setOnAction( actionEvent -> {
stackPane.getChildren().get(1).toFront();
}
Instead of using .get(1) i want to use the variable's name : tabpaneSubs
How do i do that ?