Just a quick newbie question, can you use stylesheets on components. I tried with a button the preview in scene builder looked ok but when I ran the app with b4j I got an error:
com.sun.javafx.fxml.PropertyNotFoundException: Property "stylesheets" does not exist or is read-only.
If I add the style elements manually in scene builder it works.
Thanks, I still had no luck so as I was using Scene builder v2.0 I tried v1.1 and recreated the same project from scratch and it worked. I then had a look at the fxml file(s) and they were different. The stylesheet tag was different. I have zipped the 2 fxml files if you want to look at them.. The 'test.fxml' was v1.1 and 'test2.fxml' was with v2.0
Thanks, I still had no luck so as I was using Scene builder v2.0 I tried v1.1 and recreated the same project from scratch and it worked. I then had a look at the fxml file(s) and they were different. The stylesheet tag was different. I have zipped the 2 fxml files if you want to look at them.. The 'test.fxml' was v1.1 and 'test2.fxml' was with v2.0
This is the project is just a test to work with css....the fxml file test.fxml was created with scene builder v2.0 it is the one not working. I created the same file in v1.1 which is called testy.fxml it does work if you rename it to test.fxml all works fine.