Ask coding questions

← Back to all posts
Is there anyway to run this program on repl?
Chill16 (1)

I am trying to practice with exercises out of a java textbook but when I reached the GUI section I couldn't get repl to run any of the programs without getting a barrage of errors. Is there any way to run these programs?


OldWizard209 (1537)

this is because you haven't got these packages installed:

import javafx.application.Application;
import javafx.scene.layout.BorderPane;
import javafx.scene.Scene;
import javafx.stage.Stage;
import javafx.scene.canvas.Canvas;
import javafx.scene.canvas.GraphicsContext;
import javafx.scene.paint.Color;

Install these packages and then it should run properly.
Here is a guide to install javafx: