I'm trying to open the SDK Manager using Eclipse but the following error appears:
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/swt/widgets/Display
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at com.android.sdkmanager.Main.showSdkManagerWindow(Main.java:346)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at com.android.sdkmanager.Main.doAction(Main.java:320)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at com.android.sdkmanager.Main.run(Main.java:120)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at com.android.sdkmanager.Main.main(Main.java:103)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.widgets.Display
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at java.net.URLClassLoader1ドル.run(Unknown Source)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at java.net.URLClassLoader1ドル.run(Unknown Source)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at java.security.AccessController.doPrivileged(Native Method)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at java.net.URLClassLoader.findClass(Unknown Source)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at java.lang.ClassLoader.loadClass(Unknown Source)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] at java.lang.ClassLoader.loadClass(Unknown Source)
[2013年12月16日 23:21:25 - SDK Manager] [SDK Manager] ... 4 more
I have tried almost everything:
- Fixing the Environment Path
- Reinstalling Java
- Reinstalling Android SDK
- Edit android.bat
- Edit Java paths in Eclipse
And so on..
What is really strange, is that today I've ran Eclipse in another computer almost the same as mine and, like magic, it worked perfectly, I opened SDK Manager without errors.
I didn't figured out what's the difference. Both computers uses Windows 7 Pro 64bits. Java paths are the same as well.
So, can anyone help me? =/
-
you didn't mention whether you had reinstalled Eclipse. If not, download the latest one, and have a try.yushulx– yushulx2013年12月17日 01:59:54 +00:00Commented Dec 17, 2013 at 1:59
-
Oh sorry, I installed Eclipse with Android SDK. I downloaded it in the Google Developer website. But I don't think that Eclipse or SDK is the problem, as it run without problem in the other computer.xadun– xadun2013年12月17日 10:50:47 +00:00Commented Dec 17, 2013 at 10:50
1 Answer 1
I fixed it! Just entered in the Enviroment Variables and deleted the followings:
- ANDROID_STUDIO_JDK
- ANDROID_SWT
- JAVA_HOME
- JDK_HOME
- PATH
I can't explain why it worked, but it doesn't matter now! :P