This discussion is archived
2 Replies Latest reply: Feb 2, 2013 2:47 AM by 987579 RSS

Strange behaviour inside browser

987579 Newbie
Currently Being Moderated
I'm trying to create login system with JApplet. I'm using jdbc:mysql Driver. Inside eclipse, everything works fine. But when I add my applet inside browser. In Applet console I'm getting this error:

java.lang.reflect.InvocationTargetException
     at java.awt.EventQueue.invokeAndWait(Unknown Source)
     at javax.swing.SwingUtilities.invokeAndWait(Unknown Source)
     at kurybinis.Pagrindine.init(Pagrindine.java:23)
     at sun.applet.AppletPanel.run(Unknown Source)
     at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ExceptionInInitializerError
     at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:315)
     at java.sql.DriverManager.getConnection(Unknown Source)
     at java.sql.DriverManager.getConnection(Unknown Source)
     at kurybinis.Pagrindine.prisijungtiPrieBazes(Pagrindine.java:45)
     at kurybinis.Pagrindine$1.run(Pagrindine.java:25)
     at java.awt.event.InvocationEvent.dispatch(Unknown Source)
     at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
     at java.awt.EventQueue.access$200(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.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)
Caused by: java.security.AccessControlException: access denied ("java.util.PropertyPermission" "file.encoding" "read")
     at java.security.AccessControlContext.checkPermission(Unknown Source)
     at java.security.AccessController.checkPermission(Unknown Source)
     at java.lang.SecurityManager.checkPermission(Unknown Source)
     at java.lang.SecurityManager.checkPropertyAccess(Unknown Source)
     at java.lang.System.getProperty(Unknown Source)
     at com.mysql.jdbc.StringUtils.<clinit>(StringUtils.java:70)
     ... 19 more
java.net.MalformedURLException: no protocol:
     at java.net.URL.<init>(Unknown Source)
     at java.net.URL.<init>(Unknown Source)
     at java.net.URL.<init>(Unknown Source)
     at sun.plugin.liveconnect.SecureInvocation.checkLiveConnectCaller(Unknown Source)
     at sun.plugin.liveconnect.SecureInvocation.access$000(Unknown Source)
     at sun.plugin.liveconnect.SecureInvocation$2.run(Unknown Source)
     at java.security.AccessController.doPrivileged(Native Method)
     at sun.plugin.liveconnect.SecureInvocation.CallMethod(Unknown Source)


at kurybinis.Pagrindine.prisijungtiPrieBazes(Pagrindine.java:53)

at kurybinis.Pagrindine$1.run(Pagrindine.java:34)

at java.awt.event.InvocationEvent.dispatch(Unknown Source)

at java.awt.EventQueue.dispatchEventImpl(Unknown Source)

at java.awt.EventQueue.access$200(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.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)

java.net.MalformedURLException: no protocol:
at java.net.URL.<init>(Unknown Source)

at java.net.URL.<init>(Unknown Source)

at java.net.URL.<init>(Unknown Source)

at sun.plugin.liveconnect.SecureInvocation.checkLiveConnectCaller(Unknown Source)

at sun.plugin.liveconnect.SecureInvocation.access$000(Unknown Source)

at sun.plugin.liveconnect.SecureInvocation$2.run(Unknown Source)

at java.security.AccessController.doPrivileged(Native Method)

at sun.plugin.liveconnect.SecureInvocation.CallMethod(Unknown Source)


How can I fix this? Where is the problem?

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points