java.lang.NoClassDefFoundError:无法初始化类 javax.swing.UIManager

发布于 2024-11-27 00:51:26 字数 1108 浏览 3 评论 0原文

我遇到了这个错误,有人知道这是为什么吗? Java版本:1.6.0_16

java.lang.NoClassDefFoundError: Could not initialize class javax.swing.UIManager
    at javax.swing.LookAndFeel.installColorsAndFont(LookAndFeel.java:191)
    at ilog.views.chart.IlvChart.updateUI(Unknown Source)

并且它打印另一个错误:

java.lang.UnsatisfiedLinkError: shell32.dll: Cannot load shell32.dll from system directories.
    at sun.awt.windows.WDesktopProperties.init(Native Method)
    at sun.awt.windows.WDesktopProperties.<init>(WDesktopProperties.java:66)
    at sun.awt.windows.WToolkit.lazilyInitWProps(WToolkit.java:817)
    at sun.awt.windows.WToolkit.lazilyLoadDesktopProperty(WToolkit.java:807)
    at java.awt.Toolkit.getDesktopProperty(Toolkit.java:1759)
    at java.awt.Toolkit.getDesktopProperty(Toolkit.java:1740)
    at javax.swing.UIManager.<clinit>(UIManager.java:357)
    at javax.swing.LookAndFeel.installColorsAndFont(LookAndFeel.java:191)
    at ilog.views.chart.IlvChart.updateUI(Unknown Source)

它们之间有任何深入的关系吗?

I have meet this error,does anyone know why is it? Java Version: 1.6.0_16

java.lang.NoClassDefFoundError: Could not initialize class javax.swing.UIManager
    at javax.swing.LookAndFeel.installColorsAndFont(LookAndFeel.java:191)
    at ilog.views.chart.IlvChart.updateUI(Unknown Source)

and it print another error that:

java.lang.UnsatisfiedLinkError: shell32.dll: Cannot load shell32.dll from system directories.
    at sun.awt.windows.WDesktopProperties.init(Native Method)
    at sun.awt.windows.WDesktopProperties.<init>(WDesktopProperties.java:66)
    at sun.awt.windows.WToolkit.lazilyInitWProps(WToolkit.java:817)
    at sun.awt.windows.WToolkit.lazilyLoadDesktopProperty(WToolkit.java:807)
    at java.awt.Toolkit.getDesktopProperty(Toolkit.java:1759)
    at java.awt.Toolkit.getDesktopProperty(Toolkit.java:1740)
    at javax.swing.UIManager.<clinit>(UIManager.java:357)
    at javax.swing.LookAndFeel.installColorsAndFont(LookAndFeel.java:191)
    at ilog.views.chart.IlvChart.updateUI(Unknown Source)

does them have any relations indeep?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

鹤仙姿 2024-12-04 00:51:26

假设您在 Windows 上运行,shell32.dll 应该位于您的 system32 文件夹中,例如 c:\Windows\System32\shell32.dll

如果没有它,您似乎不可能运行 Windows...也许您的 JDK/JRE 已以某种方式损坏?也许注册表项误入歧途?可能值得重新安装 JDK/JRE - 如果您使用的是 64 位计算机,请确保安装 64 位版本。虽然我希望 32 位版本也能工作(就像 64 位 Windows 上的任何其他 32 位应用程序一样),但可以想象它会导致此类问题。

Assuming you're running on Windows, shell32.dll should be in your system32 folder, e.g. c:\Windows\System32\shell32.dll.

It seems unlikely that you'd be able to run Windows without it... perhaps your JDK/JRE has become corrupt somehow? Maybe a registry entry gone astray? Possibly worth reinstalling just the JDK/JRE - and if you're on a 64-bit machine, make sure you install a 64-bit version. While I'd expect the 32-bit version to work too (like any other 32-bit application on 64-bit Windows) it's just about conceivable that it would lead to this sort of problem.

阳光的暖冬 2024-12-04 00:51:26

我卸载并重新安装了 JDK,然后在 Eclipse 中尝试使用 WindowBuilder 编辑器时遇到了此错误。

我通过重新启动 Eclipse 解决了该问题。

I uninstalled and reinstalled my JDK, and then ran into this error while trying to use the WindowBuilder Editor in Eclipse.

I fixed the problem by restarting Eclipse.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文