首页 > 解决方案 > 用launch4j包裹的应用程序图标在taskar中没有改变

问题描述

我使用 launch4j 将 app.jar 包装到 app.exe 中,桌面上出现的图标是正确的

在此处输入图像描述

但在 Windows 任务栏中我仍然有 java 图标

在此处输入图像描述

任何解决方案?

标签: launch4j

解决方案


Launch4J's only job is to wrap your .jar into .exe, thus it can only set the icon for the exe.

If you want to have a custom icon in the taskbar and in your window, you must set a custom icon in your Java code. The solution for that depends on whether you use SWT, Swing, etc. But is should come down to getting the icon from the resources and setting it in your Window/Frame/...

For example: How do I change the default application icon in Java?


推荐阅读