Developed an Android program that always shows that it cannot run and then exits. But there was no error. Ask the great God to save!

Source: Internet
Author: User

============ Problem Description ============


Developed an Android program that always shows that it cannot run and then exits. But there was no error. Ask the great God to save!
The code is as follows:

On the internet, someone says it's a intent problem.
There was no problem when I didn't join the listener.
I am a novice, the problem is a bit out of level ~
Ask the great God. Thanks thanks

============ Solution 1============


Post the log to see if the activity is not in the manifest statement

============ Solution 2============


Setonclicklistener The new Helplistener the type in front of it.

============ Solution 3============


Remove the type conversion from the front of new Helplistener!!

============ Solution 4============


Onclicklistener There are many, you use the dialog box type should not be able to function on the button, instead of View.onclicklistener

============ Solution 5============


Add a line number to the code, man.

============ Solution 6============


3 Floor positive solution, class do not change, dialog box listener and view is not the same

============ Solution 7============


Hey, you should write a view at implements. Onclicklistener

Developed an Android program that always shows that it cannot run and then exits. But there was no error. Ask the great God to save!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.