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 (retired 2014) Getting Started with Android Adding an OnClickListener to a Button

Ricky Sparks
Ricky Sparks
22,249 Points

Crystal Ball app will not open in emulator? and says "Unfortunately, Crystal ball has stopped."

The emulator works but app will not open in it???

2 Answers

Harry James
Harry James
14,780 Points

This means that something's wrong in your code somewhere!

If you post your MainActivity.java code on here somewhere (Remember to use the code formatting or use a site like www.pastebin.com) then someone will be able to take a look at it and see where you've gone wrong.

If nobody answers this today, I will be able to answer it tomorrow for you (I'm in the UK so, it's late now!)

Ricky Sparks
Ricky Sparks
22,249 Points

Thanks I found it was my java code. It needed the button cast.

Harry James
Harry James
14,780 Points

Awesome! Glad to hear you fixed it!