How do I work with JavaFX in Eclipse Juno?

后端 未结 2 854
栀梦
栀梦 2020-12-20 11:26

I have installed jdk1.7.0_15.

JavaFX\'s download page says the following:

JavaFX 2.2.7 contains the latest security fixes an

2条回答
  •  悲&欢浪女
    2020-12-20 12:05

    Great question. I remember having the same problem when I started. Here is a little step by step guide.

    1) Make a new JavaFx project (This is actually the same as a Java project, it just comes with a more suitable skeleton)
    2) If you're getting errors like 'Can't find javafx.application' add the jfxrt.jar by right clicking on the libraries and select 'Add folder/Jar' You will have to browse to your jdk folder and find jfxrt.jar. Here is where it is located in my jdk:
    /jdk1.7.0_15/jre/lib/jfxrt.jar
    3) For the third step I suggest checking out this example. This example comes with sample code and I used it to copy and paste till I got a little more comfortable in javafx.

提交回复
热议问题