Javafx won't modify label content inside multiple Panes
<p>I have an issue with my code. This is my first application with UI. I declared my label, tried to bind a value and modify it, but nothing happens. Obviously the problem is my label is inside a pane which is inside an other pane. How can I modify my label in this case?</p>

<p>Main.java</p>

<pre><code>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 {
        Parent root = FXMLLoader.load(getClass().getResource("fxml/gui.fxml"));
        primaryStage.setTitle("program name");
        primaryStage.setScene(new Scene(root, 1280, 720));
        primaryStage.show();
    }

    public static void main(String[] args) {
        launch(args);
    }
}
</code></pre>

<p>myClasses\Controller.java</p>

<pre><code>package myClasses;

import javafx.beans.property.SimpleIntegerProperty;
import javafx.fxml.Initializable;
import javafx.scene.control.Button;
import javafx.scene.control.Label;
import java.net.URL;
import java.util.ResourceBundle;

public class Controller implements Initializable{

    public Button hourglass;
    public Label currentMonthLabel;
    public SimpleIntegerProperty pastMonths = new SimpleIntegerProperty(1);

    @Override
    public void initialize(URL location, ResourceBundle resources) {
        currentMonthLabel.textProperty().bind(pastMonths.asString());
        hourglass.setOnAction(e-&gt; {
            pastMonths.setValue(pastMonths.getValue() + 1);
            System.out.println(pastMonths.getValue());
        });
    }
}
</code></pre>

<p>fxml\gui.fxml</p>

<pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;?import javafx.scene.control.*?&gt;
&lt;?import javafx.scene.layout.*?&gt;

&lt;AnchorPane fx:controller="myClasses.Controller" fx:id="anchorPane" maxHeight="1280.0" maxWidth="1280.0" minHeight="1280.0" minWidth="720.0" prefHeight="720.0" prefWidth="1280.0" xmlns="http://javafx.com/javafx/8" xmlns:fx="http://javafx.com/fxml/1"&gt;
   &lt;children&gt;
      &lt;SplitPane dividerPositions="0.1" orientation="VERTICAL" prefHeight="720.0" prefWidth="1280.0"&gt;
        &lt;items&gt;
          &lt;AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="546.0" prefWidth="1756.0"&gt;
               &lt;children&gt;
                  &lt;HBox prefHeight="0.0" prefWidth="0.0"&gt;
                     &lt;children&gt;
                        &lt;Label minHeight="16.0" minWidth="40.0" text="Money:" /&gt;
                        &lt;Label fx:id="moneyLabel" minHeight="16.0" minWidth="40.0" text="" /&gt;
                     &lt;/children&gt;
                  &lt;/HBox&gt;
               &lt;/children&gt;&lt;/AnchorPane&gt;
          &lt;AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="100.0" prefWidth="160.0"&gt;
               &lt;children&gt;
                  &lt;TabPane prefHeight="645.0" prefWidth="1280.0" tabClosingPolicy="UNAVAILABLE"&gt;
                    &lt;tabs&gt;
                        &lt;Tab text="Help"&gt;
                          &lt;content&gt;
                            &lt;AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="180.0" prefWidth="200.0" /&gt;
                          &lt;/content&gt;
                        &lt;/Tab&gt;
                        &lt;Tab text="AnotherTab"&gt;
                          &lt;content&gt;
                            &lt;AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="180.0" prefWidth="200.0"&gt;
                                 &lt;children&gt;
                                    &lt;Button fx:id="hourglass" layoutX="282.0" layoutY="78.0" mnemonicParsing="false" text="Next Month" /&gt;
                                 &lt;/children&gt;&lt;/AnchorPane&gt;
                          &lt;/content&gt;
                        &lt;/Tab&gt;
                    &lt;/tabs&gt;
                  &lt;/TabPane&gt;
               &lt;/children&gt;&lt;/AnchorPane&gt;
        &lt;/items&gt;
      &lt;/SplitPane&gt;
   &lt;/children&gt;
&lt;/AnchorPane&gt;
</code></pre>