Posts by Gustavo Fragoso • 2,321 points
112 posts
-
1
votes1
answer250
viewsA: Matching of combobox contents
Assuming your table in the database is something like: +-------+-------+ | Col 1 | Col 2 | +-------+-------+ | 1 | A | +-------+-------+ | 2 | B | +-------+-------+ | ... | ... | +-------+-------+…
javafxanswered Gustavo Fragoso 2,321 -
1
votes2
answers854
viewsA: Imageview inside Hbox in FXML file
Your FXML code lacks the tag <children></children> within Hbox (No Borderpane also): // Supondo que sua pasta images está dentro da pasta src <HBox> <children> // Esta tag…
-
0
votes1
answer183
viewsA: Addall items in combobox
Note that the method getItems() of the combobox returns a Observablelist. Why don’t you try manually setting the Observablelist of your Combobox, thus: private ComboBox<String> meuCombo;…
-
0
votes2
answers816
viewsA: How to save a file to Javafx or Java?
Javafx provides a window to open/save files through the class Filechooser, that can help solve your problem and also improve the usability of your software. Here is the code needed to save a text…
-
0
votes1
answer99
viewsA: Writing files to Java
Printing only the first element because you close your Filewriter after the first if entry in that part here: FileWriter gravador = new FileWriter(medias, true); for (int p = 0; p <=…
javaanswered Gustavo Fragoso 2,321 -
0
votes1
answer34
viewsA: Check if a field is bindBidirectional (Javafx)
Just use the . isBound() method of the property: if(txt2.textProperty().isBound()){ // Propriedade linkada }else{ // Propriedade não linkada }
javafxanswered Gustavo Fragoso 2,321 -
0
votes3
answers851
viewsA: How to create a stopwatch in Javafx using Scene Builder?
I managed to do it two different ways. Approach 1: Use a normal Task and update the label via a bind with the thread messageProperty(): Task<Void> task = new Task<Void>() { @Override…
-
1
votes1
answer88
viewsA: Pane recovered from fxml file come null
Your null panel’s FXML does not have a controller, represented by the tag: fx:controller, so you must assign or create a controller for your Pane. Using your own code as an example, your dashboard…
javafxanswered Gustavo Fragoso 2,321 -
1
votes2
answers1251
viewsA: Javafx Threads Update UI and load System in the background
An elegant way to solve your problem is to create a Preloader, considered a good programming practice in Javafx. Preloader is especially useful for improving the user experience when it needs to…
-
0
votes1
answer423
viewsA: How to delete item from a Combobox after selecting it?
Try to adapt solution following to your context: (As I have no way to simulate your context tested only with index removal) combobox.setOnHidden((event) -> { int index =…
javafxanswered Gustavo Fragoso 2,321 -
0
votes1
answer243
viewsA: Fieldset in Javafx
This component does not exist in Javafx or the main UI Controls add-on (Controlsfx), therefore it is not present in Scenebuilder. However, I believe that you can achieve a similar functionality…
-
2
votes1
answer294
viewsA: Javafx Pagination
Pagination needs pages created by pageFactory to work properly. For this you use the function . setPageFactory(), as shown below: pagination.setPageFactory(new Callback<Integer, Node>() {…