how to link javafx modules directly to jdk as it was done in jdk 9 and lower version[CLOSED] | Sololearn: Learn to code for FREE!
Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite
0

how to link javafx modules directly to jdk as it was done in jdk 9 and lower version[CLOSED]

I want to link JavaFX-20 with JDK-19 such that I don't need to specify module-path every time. Operating System:Linux (A container -> no privilege) Compiler: Replit

1st May 2023, 4:27 PM
I am offline
I am offline - avatar
11 Réponses
+ 4
Cause JavaFX was introduced as part of the Java 8 release. However, it was later removed from the JDK and moved to a separate module in Java 11. If you are using the newer version of Java 11+, you will need to obtain the dependencies separately. Use a dependency management system such as Maven or Gradle..
1st May 2023, 6:24 PM
Smith Welder
Smith Welder - avatar
+ 3
The searches I made returned old threads, so I'm not sure if replit support for java fx have been updated, but I didn't get any positive result. https://replit.com/talk/ask/Can-JavaFX-programs-work-in-replit/45311 Well, there is one that suggested including the library in the file... but really? Why not just use Swing? While Googling Java GUI, I came across JSF. Looks interesting. https://www.tutorialspoint.com/jsf/index.htm0
2nd May 2023, 4:47 AM
Bob_Li
Bob_Li - avatar
+ 2
Open replit. Go to the Java repl, after, go to the console/terminal and type this: rm * mvn archetype:generate After you will see Maven java build tools. If you'll have some questions, don't be shy, ask about in replit support. PS if it's seems for you too hard, so use intellij IDEA, File-> New ->Project->JavaFX..
1st May 2023, 7:52 PM
Smith Welder
Smith Welder - avatar
+ 2
Bob_Li actually there are some project rules to use specified modules thanks for pointing but I would say that I was successful in running fx application but by specifying module-path so I just wanna reduce it but now I think using maven is good idea
2nd May 2023, 5:03 AM
I am offline
I am offline - avatar
+ 2
Snehil Maven is good. But I feel it's overkill for simple projects. Glad to know you made it work. But fixing your PC limitation feels like the more pressing problem. Using replit is clever, but it is still just a workaround.
2nd May 2023, 5:11 AM
Bob_Li
Bob_Li - avatar
+ 2
if there is no pc or some limitations, then can make it from phone, install Linux, connect a keyboard, install an soft(editor, etc..). Connect all this to a TV (if has), it will be like a monitor. Union a several phones to get more performance..
2nd May 2023, 6:02 AM
Smith Welder
Smith Welder - avatar
+ 2
Smith Welder well as a high school student I can't go that far you can understand
2nd May 2023, 6:59 AM
I am offline
I am offline - avatar
+ 1
Mirielle I'm not running any bash command I'm directly editing my JDK for usage so I don't think there's a need to add more details But yeah I think I need to mention operating system: Linux and as per IDE I'm using replit but I don't want temporary solution like editing .barshrc or adding any source rather directly edit the JDK
1st May 2023, 5:27 PM
I am offline
I am offline - avatar
+ 1
Smith Welder good ideaūüĎć lemme try
1st May 2023, 6:27 PM
I am offline
I am offline - avatar
+ 1
Smith Welder well your idea will actually work but the thing is that how can I install maven on replit as I've no privilege
1st May 2023, 7:21 PM
I am offline
I am offline - avatar
0
Smith Welder I'm using replit due to some limitations my PC is not in working conditions. Thank you for helping
2nd May 2023, 3:52 AM
I am offline
I am offline - avatar