1

I am using dialogs in my javaFX application in order to show background processes in running.However when i am opening same source code in eclipse on other computers it throws errors.here is code for dialog which one i am using

Dialogs.create().owner(null).title("Kalculate - New Company")
            .masthead(data + companyName).message("In progress")
            .showWorkerProgress(companyService);

and here is corresponding errors

Caused by: java.lang.NoClassDefFoundError: Could not initialize class  org.controlsfx.dialog.HeavyweightDialog
    at org.controlsfx.dialog.Dialog.(Dialog.java:340)
    at org.controlsfx.dialog.Dialogs.buildDialog(Dialogs.java:1009)
    at org.controlsfx.dialog.Dialogs.showWorkerProgress(Dialogs.java:885)
    at com.openlx.kalculate.controllers.masters.NewCompany.saveButtonOnAction(NewCompany.java:864)
ItachiUchiha
  • 36,135
  • 10
  • 122
  • 176
  • 1
    Check the versions of Java you're running between the different computers. I had this same issue between ControlsFX 8.40.9 and 8.40.10 as they support different Java versions (< 8u20 and > 8u40 respectively) See http://fxexperience.com/controlsfx/ Getting ControlsFX section – Miles Mar 09 '16 at 07:01

1 Answers1

2

This due to The class com.sun.javafx.Utils was moved to com.sun.javafx.util.Utils package in update 60 of Java 8. So you might have to restrict your java version to 1.8.0_45 or below if possible.Or try to use latest ControlFx.

manikant gautam
  • 3,521
  • 1
  • 17
  • 27