Skip to main content

Please help I got An error has occurred during startup

1 reply [Last post]
gdavis480
Offline
Joined: 2013-10-29
Points: 0

How can I get rid of this error?

java.lang.ClassNotFoundException: pcloud.systemtray.ASPAgent
at java.net.URLClassLoader$1.run(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at com.exe4j.runtime.LauncherEngine.launch(Unknown Source)
at com.exe4j.runtime.WinLauncher.main(Unknown Source)
at com.install4j.runtime.launcher.WinLauncher.main(Unknown Source)

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
arnavkumartechno
Offline
Joined: 2013-10-25
Points: 0

How to fix java.lang.ClassNotFoundException in Java
As you have seen from above examples its clear problem of classpath, so here is my approach to fix or resolve java.lang.ClassNotFoundException:

1) First find out the jar file on which problematic class file is present for example in case of "pcloud.systemtray.ASPAgent". If you don't know how to find which jar file a particular class you can see eclipse shortcuts to do that or you can simply do "Ctrl+T" in Eclipse and type the name of class, It will list all the jar in the order they appear in eclipse classpath.

2) Check whether your classpath contains that jar, if your classpath doesn't contain the jar then just add that class in your classpath.

3) If it’s present in your classpath then there is high chance that your classpath is getting overridden or application is using classpath specified in jar file or start-up script and to fix that you need to find the exact classpath used by your application.

TechKnowHeithts