Error when using CustomStage with java 17 and openjfx 17

when I try to run my project, I get the following error: Error occurred during initialization of boot layer java.lang.module.FindException: Module CustomStage not found, required by com.example.jfxmoderntest
Execution failed for task ':HelloApplication.main()'.
> Process 'command '/usr/lib/jvm/java-1.17.0-openjdk-amd64/bin/java'' finished with non-zero exit value 1
Execution failed for task ':HelloApplication.main()'.
> Process 'command '/usr/lib/jvm/java-1.17.0-openjdk-amd64/bin/java'' finished with non-zero exit value 1
What does this mean and how could I fix it? I am using gradle, so here is an except of my build.gradle:
dependencies {
implementation('lk.vivoxalabs.customstage:CustomStage:1.3.2')
implementation('org.controlsfx:controlsfx:11.1.2')
implementation('com.dlsc.formsfx:formsfx-core:11.6.0') {
exclude(group: 'org.openjfx')
}
implementation('net.synedra:validatorfx:0.4.0') {
exclude(group: 'org.openjfx')
}
implementation('org.kordamp.ikonli:ikonli-javafx:12.3.1')

testImplementation("org.junit.jupiter:junit-jupiter-api:${junitVersion}")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:${junitVersion}")
}
dependencies {
implementation('lk.vivoxalabs.customstage:CustomStage:1.3.2')
implementation('org.controlsfx:controlsfx:11.1.2')
implementation('com.dlsc.formsfx:formsfx-core:11.6.0') {
exclude(group: 'org.openjfx')
}
implementation('net.synedra:validatorfx:0.4.0') {
exclude(group: 'org.openjfx')
}
implementation('org.kordamp.ikonli:ikonli-javafx:12.3.1')

testImplementation("org.junit.jupiter:junit-jupiter-api:${junitVersion}")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:${junitVersion}")
}
6 Replies
JavaBot
JavaBot2y ago
This post has been reserved for your question.
Hey @NeoCortex97! Please use /close or the Close Post button above when you're finished. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
NeoCortex97
NeoCortex97OP2y ago
Sure, but it is only the example from the customstage docs.
package com.example.jfxmoderntest;

import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.stage.Stage;
import lk.vivoxalabs.customstage.CustomStage;
import lk.vivoxalabs.customstage.CustomStageBuilder;

import java.io.IOException;

public class HelloApplication extends Application {
@Override
public void start(Stage primaryStage) throws IOException {
CustomStage stage = new CustomStageBuilder()
.setWindowTitle("ModernUI")
.setIcon(String.valueOf(this.getClass().getResource("LOGO_24.png")))
.build();
FXMLLoader fxmlLoader = new FXMLLoader(HelloApplication.class.getResource("MainView.fxml"));
Scene scene = new Scene(fxmlLoader.load(), 320, 240);
// stage.changeScene(scene);
stage.show();
}

public static void main(String[] args) {
launch();
}
}
package com.example.jfxmoderntest;

import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.stage.Stage;
import lk.vivoxalabs.customstage.CustomStage;
import lk.vivoxalabs.customstage.CustomStageBuilder;

import java.io.IOException;

public class HelloApplication extends Application {
@Override
public void start(Stage primaryStage) throws IOException {
CustomStage stage = new CustomStageBuilder()
.setWindowTitle("ModernUI")
.setIcon(String.valueOf(this.getClass().getResource("LOGO_24.png")))
.build();
FXMLLoader fxmlLoader = new FXMLLoader(HelloApplication.class.getResource("MainView.fxml"));
Scene scene = new Scene(fxmlLoader.load(), 320, 240);
// stage.changeScene(scene);
stage.show();
}

public static void main(String[] args) {
launch();
}
}
JavaBot
JavaBot2y ago
💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one.
NeoCortex97
NeoCortex97OP2y ago
This issue was a little urgent, but now it is not really anymore
JavaBot
JavaBot2y ago
💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one.
Want results from more Discord servers?
Add your server