I especially have a problem with the readability of your code.
Don't just put everything in your startmethod, JavaFx uses controllers for a reasson.
It's also unclear to me, why you're opening a file in three different locations.
This is an exampe of a program that let's you open, edit and save a textfile.
For this example I maded the file and the list containing the files static, in production you would find a cleaner solution for that:
As you can see, when you try to edit a file an textarea is loaded in the center of the borderpane containing the text of the file.
After editing the file is overwritten.
For this example you can only edit the file you last loaded, Ideally you would have a way to choose which file you want to edit.
A final tip. I myself am a big fan of seperating the desing of your fxml file from your businesslogic, ergo your fxmlfile should contain all your design.
If you don't know how to edit a fxmlfile, use scenebuilder, which you can download here or most idea's (like netbeans, intelij and eclipse) have build in plugin's.
Removing the desing from your controller (or in your case your startmethod) will greatly improve your readability.
It's good to be able to use someting, it's better to understand how it works.
So when I tried to run the program you shown me, it gave me this error message:
java.lang.RuntimeException: Exception in Application start method
what does it mean? Does it mean that it could not load the .fxml file?
Sorry for the beginner question. I haven't got into learning much about JavaFX design.