How i load up css file from inside a method ..? : /* This is Controller.java Class .. i want load up another css file from inside a method. I tried blow codes but unluckly dont work.now i how to load up another css file ? [N.B: sorry,for my bad english]


 @FXML
    private Button mbut1;
   @FXML
    private void menubut1(ActionEvent event) {
      
        mbut1.getStylesheets().add(getClass().getResource("dinner.css" ).toExternalForm());
      
        
       
        
        