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) Basic Android Programming Initializing a Button

david boggild
david boggild
237 Points

I keep getting the following error message when I try to run my fun facts app. I not sure how to fix the error?

Error:(18, 9) error: cannot find symbol class textview Error:(18, 31) error: cannot find symbol class textview Error:Execution failed for task ':app:compileDebugJava'.

Compilation failed; see the compiler error output for details.

In my activity area the following imports are showing but I haven`t got an import for Textview. I have tried to add the following line manually "import andriod.widget.Textview; but it will not work.

import android.app.Activity; import android.os.Bundle; import android.view.Menu; import android.view.MenuItem; import android.widget.Button;

2 Answers

Matthew Ong
Matthew Ong
6,041 Points

Remember that Java is a case-sensitive language. Try changing textview to TextView

david boggild
david boggild
237 Points

Hi Matthew its working now thanks for the help