Intellij wont recognize javafx imports

Answered

I am utterly confused. I try to start a JavaFx application on my mac and it works without any problems. I try and do the same thing on my Windows 10 machine and I cant even run the sample code provided with the JavaFx Application template. Any class/library from the JavaFx library is highlighted red and when you hover over it it says "Can't resolve Symbol 'javafx'". I have JDK 13.0.1 selected SDKs in the Project Structure dialog box and it still doesn't work. How can I fix this.

1
2 comments

JDK doesn't come with JavaFX, it has to be installed manually, see https://openjfx.io/openjfx-docs/ .

1
Avatar
Permanently deleted user

Thanks that worked perfectly. Its strange how it worked without having to do this on my mac. Maybe somehow I already had JavaFx installed on it.

0

Please sign in to leave a comment.