Problem loading FXML files [message #1424135] |
Mon, 15 September 2014 10:10  |
Eclipse User |
|
|
|
Hello,
I'm experiencing some trouble loading FXML-files in my efx4 application.
According to the recipe (https://wiki.eclipse.org/Efxclipse/Runtime/Recipes#.40FXMLLoader) I should use the following code snippet :
Quote:
public class MyLoginView {
@PostConstruct
void init(BorderPane p, @FXMLLoader FXMLLoaderFactory factory) {
GridPane p = factory.loadRequestorRelative("myLoginView.fxml").build();
// ...
}
However, this code gives me errors :
* first of all, type mismatch and duplicate local variable -> solved by leaving out "GridPane".
* ".build()" gives the error "The method build is indefined for the type FXMLBuilder<Object>"
* when changing "build()" to "load()", the application finally starts up but the widget is empty.
Any cues as how this code can be made to work ?
Is there any other example on how to load FXML files in a efx4 application ?
Just in case : I've not forgotten to link the class MyLoginView to the application model.
Thanks in advance,
Thomas Elskens
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03044 seconds