-1

I created an exe file of my Java application which got created successfully. But when I try ans execute it and place some values in the form displayed , press submit button , it is showing the error:

Executing: C:\Users\bhawna\Desktop\tto1.exe
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver   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 java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at ngo_interface.eventdetail.jButton1ActionPerformed(eventdetail.java:192) at ngo_interface.eventdetail.access$300(eventdetail.java:20) at ngo_interface.eventdetail$4.actionPerformed(eventdetail.java:89) at javax.swing.AbstractButton.fireActionPerformed(Unknown Source) at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source) at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source) at javax.swing.DefaultButtonModel.setPressed(Unknown Source) at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source) at java.awt.Component.processMouseEvent(Unknown Source) at javax.swing.JComponent.processMouseEvent(Unknown Source) at java.awt.Component.processEvent(Unknown Source) at java.awt.Container.processEvent(Unknown Source) at java.awt.Component.dispatchEventImpl(Unknown Source) at java.awt.Container.dispatchEventImpl(Unknown Source) at java.awt.Component.dispatchEvent(Unknown Source) at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source) at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source) at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source) at java.awt.Container.dispatchEventImpl(Unknown Source) at java.awt.Window.dispatchEventImpl(Unknown Source) at java.awt.Component.dispatchEvent(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$000(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue$4.run(Unknown Source) at java.awt.EventQueue$4.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source)

What should I do? The values are not going in the database.
This is the log file of launch4j:

CmdLine:    C:\Users\bhawna\Desktop\ttf1.exe --l4j-debug
WOW64:      yes
Check launcher:  (n/a)
64-bit search:  SOFTWARE\JavaSoft\Java Runtime Environment...
Match:      SOFTWARE\JavaSoft\Java Runtime Environment\1.6
Match:      SOFTWARE\JavaSoft\Java Runtime Environment\1.6.0_32
Match:      SOFTWARE\JavaSoft\Java Runtime Environment\1.7
Match:      SOFTWARE\JavaSoft\Java Runtime Environment\1.7.0
Using 64-bit runtime.
64-bit search:  SOFTWARE\JavaSoft\Java Development Kit...
Ignore:     SOFTWARE\JavaSoft\Java Development Kit\1.7
Ignore:     SOFTWARE\JavaSoft\Java Development Kit\1.7.0
Using 64-bit runtime.
Check launcher: C:\Program Files\Java\jre7\bin\javaw.exe (OK)
Add classpath:  mysql-connector-java-5.0.8-bin.jar
Add classpath:  beansbindings-1.2.1.jar
Launcher:   C:\Program Files\Java\jre7\bin\javaw.exe
Launcher args:  -classpath "C:\Users\bhawna\Desktop\ttf1.exe;mysql-connector-java-5.0.8-bin.jar;beansbindings-1.2.1.jar" ngo_interface.NewJFrame
Args length:    128/32768 chars
Exit code:  0
Mahmoud Gamal
  • 78,257
  • 17
  • 139
  • 164
user1502308
  • 87
  • 1
  • 2
  • 9

1 Answers1

1

just add the mysql-connector jar file in classpath

Alya'a Gamal
  • 5,624
  • 19
  • 34