How to solve java.lang.NoClassDefFoundError?

前端 未结 27 2093
暗喜
暗喜 2020-11-21 06:04

I\'ve tried both the example in Oracle\'s Java Tutorials. They both compile fine, but at run-time, both come up with this error:

Exception in thread \"main\"         


        
27条回答
  •  半阙折子戏
    2020-11-21 06:27

    I had the same issue with my Android development using Android studio. Solutions provided are general and did not help me ( at least for me). After hours of research I found following solution and may help to android developers who are doing development using android studio. modify the setting as below Preferences ->Build, Execution, Deployment -> Instant Run -> un-check the first option.

    With this change I am up and running. Hope this will help my dev friends.

提交回复
热议问题