Android SDK Tools Rev.17 - onClick - Corresponding method handler not found

孤人 提交于 2019-12-02 06:34:25

What is the cause and solution of this problem?

The cause is your use of a string resource for the method name.

The solution is to get rid of the string resource and to put the method name in the android:onClick attribute directly.

UPDATE: If the markers do not go away, right-click over the project, and choose Android Tools > Clear Lint Markers.

Soon after update/install it shows errors. But re-running Lint corrects the problem.

Right Click Project -> Android Tools -> Click "Run Lint: Check for common Errors"

i had this same problem...

  1. check tools:context=".MainActivity" in your XML wheather its indicating to right java activity
  2. Rebuilt or clean project from build--> clean project in top menu
  3. make sure you have View in your function parameters public void onclickdo(View view)

hope this is help full

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!