title: JavaFX FXML Parameter passing from Controller A to B and back
body: <p>I want to create a controller based JavaFX GUI consisting of multiple controllers.</p>
  
  <p>The task I can't accomplish is to pass parameters from one Scene to another AND back.</p>
  
  <p>Or in other words:
  The MainController loads SubController's fxml, passes an object to SubController, switches the scene. There shall not be two open windows.
  After it's work is done, the SubController shall then switch the scene back to the MainController and pass some object back.
  This is where I fail. </p>
  
  <p>This question is very similar to this one but still unanswered. <a href="https://stackoverflow.com/questions/14187963/passing-parameters-javafx-fxml">Passing Parameters JavaFX FXML</a>
  It was also mentioned in the comments:</p>
  
  <p>"This work when you pass parameter from first controller to second but how to pass parameter from second to first controller,i mean after first.fxml was loaded.</p>
  
  <p>– Xlint Xms Sep 18 '17 at 23:15"</p>
  
  <p>I used the first approach in the top answer of that thread. </p>
  
  <p>Does anyone have a clue how to achieve this without external libs?</p>