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!
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

Kevin Tipper
126 PointsAdd cast missing in quick fixes
Hi, I'm tring to do the crystal ball project on Android, but when i hover over findViewByid the add cast to text view option doesn't appear in the quick fixes box. I am running windows 7 64bit
1 Answer

Ben Jakuben
Treehouse TeacherKevin contacted us through email and I answered him there, so I am posting it in here, too, for future reference. :)
Sorry you're having trouble! One thing that might be causing the problem is if your method name is mistyped. In your email you have "findViewByid", but the "I" in "Id" needs to be capitalized. Something like that could be preventing the Quick Fix from being generated.
If your method is correct, what happens if you add the cast manually? All you need to do is type (Button) or (TextView) in front of findViewById (depending on which you are trying to get, of course).
Here's an example:
mAnswerLabel = (TextView) findViewById(R.id.textView1);
Ernest Grzybowski
Treehouse Project ReviewerErnest Grzybowski
Treehouse Project ReviewerWhat version of Eclipse are you using?