Unfortunately App Has Stopped – How to Fix – ONLY FOR PROGRAMMERS – Android Studio Tutorial


If your Android app crashes, then because of an uncaught RuntimeException like a NullPointerException.
In this video we will learn, how to read the Logcat stack trace to find out what exception caused our app to crash and where it happened in our code, so we can provide more specific information when we ask for help.

Java RuntimeException documentation:

❗ Subscribe to the channel:

⏯ Watch more tutorials:

⭐ Become a channel member for exclusive tutorials and other perks:

㊙ Help translating the videos:

💚 Support the content:

💬 Join the Discord chat:

🎧 Audiobooks and podcasts for programmers:

👶 How to get started with Android development:

📣 Follow Coding in Flow on social media:





Nguồn: https://game911.vn

Xem thêm bài viết khác: https://game911.vn/cong-nghe/


  1. Thank you so much!!!!!!!
    but I got a weird problem..,When I first launch the app, it work perfect. But in second time, it will crash and have the error 'null pointer exception', do you know where is the problem????

  2. How are you brother, I have a problem, when I have images in my Android project and run it, no errors appear in my my project, but when I run the app on my phone, it says unfortunately app stop … and when removing the image, the app run correctly, how to fix that please?

  3. thank you thank you thaank youuu

    i was able to find that my problem was that i didn't define the activity in the manifest file

  4. bro, you save me I was scared when my app stopped working I thought all is gone now..but you explain it very well. Keep sharing your knowledge and a warm thanx from me.

  5. This is amazing, this makes it so much easier to find the error and fix it thank you very much!
    But what is the key shortcut you used to open the : "surround by" window, this will help me loads.

  6. when i click logcat , nothing found any , but my problems app force stop when i upload video ya image force stop , java.lang.r, I don't know why

  7. Thank you for the very helpful video. I am trying to debug why an app crashes when it is ran on certain devices. Would these steps help or can you provide steps to debug this problem?

  8. Thanks for the video, I'm not a programmer but this makes me want to become a programmer lol =))) btw what if this error occurred with applications installed by .apk file? Is there any way to modify the file to avoid this error? Just asking bcos I often download apk file to install apps from apktovi.com instead of the Play Store. Hope to receive your answer soon!

  9. hello sir , my problem is cause of setContentView(R.layout.main_activity); please direct me on how to fix this i am using android x its very urgent


Please enter your comment!
Please enter your name here