Uncaught Error: Could not create class com.aspose.diagram.Act

I am trying to use aspose.diagram with electron. For building I use electron forge.

What is the problem?
When building “electron-forge make”, the application is built without visible problems, but the functionality related to aspose.diagram does not work. The error I get in the console looks like this:
“Uncaught Error: Could not create class com.aspose.diagram.Act
java.lang.NoClassDefFoundError: com/aspose/diagram/Act”.

What could be the cause and how can it be solved?

@sintez
This error typically occurs when there is a problem with classpath or library dependencies.
Please ensure that you have the Aspose.Diagram for Node.js via Java library correctly added to your project. It should be in the classpath so that your application can find the necessary classes at runtime. You can usually add it as a dependency in your project’s build configuration.
Please ensure that your Java environment is properly configured. Make sure that the correct Java runtime environment (JRE) or Java Development Kit (JDK) is installed and set up on the system.
Could you please give us environment details with the version of Electron or Electron Forge,and the version of Diagram library .
Thanks.

Added a project to github with this problem.

electron forge: 6.4.2, electron: 10.1.2, aspose: 23.10.0
I really didn’t find anything related to aspose in the classpath, but explicitly adding paths didn’t solve the problem(

@sintez
Thanks for providing us locale settings details.
We will build electron in our side and evaluate your issue further and get back to you.
Thanks.

Good afternoon, any news on the problem?

@sintez
When we running with “npm start”,It shows an error “Uncaught Error: Cannot find module ‘java’” in the output app.
So we could not load file with the button.
electron.PNG (28.0 KB)

And after we running “nmp install java”,it shows “Error: Could not determine Electron version. Make sure that ‘npm install’ (or ‘yarn’) has been run before invoking electron-forge.”
We could not know the reason for this issue because we had already installed Electron previously.
We need evaluate the issue further.
Thanks.

@sintez
We got it working when clicking the button and did not find the issue of “Uncaught Error: Could not create class com.aspose.diagram.Act
java.lang.NoClassDefFoundError: com/aspose/diagram/Act”.

Could you please check the console of screenshot.
Electron.PNG (119.1 KB)

And please check if there is an “aspose.diagram” folder in the “node_modules” directory.
Thanks.

Unfortunately, I don’t have access to a screenshot.
When I click on the link, the following message is displayed: ‘Sorry, this file is private. Only visible to topic owner and staff members.’

What operating system did you run the test on? What version of nodejs did you use?

@sintez
We run in windows 10 and the version of nodejs is v14.17.6.
Electron.PNG (119.1 KB)

@sintez
Please download screenshot from this link as per your convenience.