I have this method and I draw text. I would like to change this and if I call my method it should be draw not a text but it should display an image. How to code this? Below code for a firstimage doesn't work. It displays: "Cannot resolve symbol "firstimage". But it works fine if I code the same line below for example: public class SHOWYOURTEXT extends Application {
It works for text.
private void drawTEXT(){
text.setText("TEXT");
private firstimage = new Image("file:src/main/resources/img/TEXT.png");
}