×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Text
Posted by: sumesh tg
Added: Oct 13, 2016 11:54 AM
Views: 1
Tags: loader
  1.  FXMLLoader loader = new FXMLLoader(getClass().getResource("/com/zs/ina/registration/invoice/FXMLInvoice.fxml"));
  2.         try {
  3.             /* ======================== Add Bean TO Context ==================== */
  4.             Context.getInstance().currentProfile().setCounselorDetailsTaskBEAN(counselorDetailsBEAN);
  5.             Parent root = (Parent) loader.load();
  6.             FXMLInvoiceController controller = (FXMLInvoiceController) loader.getController();
  7.             controller.initData(counselorDetailsBEAN);
  8.             vboxInvoice.getChildren().remove(0);
  9.             vboxInvoice.getChildren().add(root);
  10.         } catch (IOException exception) {
  11.             exception.printStackTrace();
  12.             logger.error(exception.getStackTrace());
  13.         }