Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Android Build a Simple Android App (2014) Improving Our Code Adding More Colors

Crashes

When i Run my app on the emulator it says

"Unfortunately, FunFacts have crashed" and the app exits out to the home screen. any way to fix this?

Mikael Enarsson
Mikael Enarsson
7,056 Points

There is probably some problem with your code, so it would be helpful if you could post it?

Harry James
Harry James
14,780 Points

Hey Jacob!

As Mikael Enarsson has said, there must be something wrong in your code!

Please paste the contents of you LogCat here after you have ran the app as shown on the image below:

LogCat

Image available in full quality here

As you can see, I have set the Log Level to error so that only the error will be displayed.

If you can't see what I can, make sure to click on the Android tab on the bottom and the Devices | logcat tab.

Hope to help you out soon! :)

Tom Latham
Tom Latham
2,591 Points

I had the same issue and then realized I had accidentally selected "showFactButton.setText(color)" instead of "showFactButton.setTextColor(color)" off the quick fill menu. Hope this helps