execute . Jar with administrative privileges (strange errors)

Asked

Viewed 136 times

0

How is it a file. Jar, to run it with administrative privileges, I ran Windows Command Prompt as administrator (with the java -jar command.jar file name) and got the following error messages.

java.lang.Exception: error loading library
java.lang.Exception: can't locate library
        at com.izforge.izpack.util.Librarian.loadArchSpecificLibrary(Librarian.java:320)
        at com.izforge.izpack.util.Librarian.loadLibrary(Librarian.java:179)
        at com.izforge.izpack.util.os.ShellLink.initialize(ShellLink.java:500)
        at com.izforge.izpack.util.os.ShellLink.<init>(ShellLink.java:374)
        at com.izforge.izpack.util.os.Win_Shortcut.initialize(Win_Shortcut.java:82)
        at com.izforge.izpack.panels.ShortcutPanel.panelActivate(ShortcutPanel.java:792)
        at com.izforge.izpack.installer.InstallerFrame.switchPanel(InstallerFrame.java:968)
        at com.izforge.izpack.installer.InstallerFrame.navigateNext(InstallerFrame.java:1653)
        at com.izforge.izpack.installer.InstallerFrame.navigateNext(InstallerFrame.java:1623)
        at com.izforge.izpack.installer.InstallerFrame$NavigationHandler.actionPerformed(InstallerFrame.java:1771)
        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$500(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$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.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$JavaSecurityAccessImpl.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.lang.NullPointerException
        at com.izforge.izpack.util.os.Win_Shortcut.getProgramsFolder(Win_Shortcut.java:679)
        at com.izforge.izpack.panels.ShortcutPanel.getProgramsFolder(ShortcutPanel.java:883)
        at com.izforge.izpack.panels.ShortcutPanel.panelActivate(ShortcutPanel.java:806)
        at com.izforge.izpack.installer.InstallerFrame.switchPanel(InstallerFrame.java:968)
        at com.izforge.izpack.installer.InstallerFrame.navigateNext(InstallerFrame.java:1653)
        at com.izforge.izpack.installer.InstallerFrame.navigateNext(InstallerFrame.java:1623)
        at com.izforge.izpack.installer.InstallerFrame$NavigationHandler.actionPerformed(InstallerFrame.java:1771)
        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$500(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$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.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$JavaSecurityAccessImpl.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)
  • Lack of dependence izpack.

  • It can also be the JDK version, check if it is 32 or 64 bits. http://www.programcreek.com/2010/03/java-lang-exception-cant-locate-library-at-com-izforge-izpack-util-librarian-loadarchspecificlibrary/

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.