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 Android Data Persistence Introduction to Data Persistence Introduction to the Starter Kit

Erin Kapoor
Erin Kapoor
412 Points

Can't Run the Application

I downloaded the files and open them, but a couple of things are happening.

1.) The run button is grayed out and I can't run anything 2.) The symbols for the java classes is different the symbol for "GridViewAdapter.java" looks like a piece of paper with a red circle with a "J" in it.

Any help would be great.

2 Answers

Harry James
Harry James
14,780 Points

Hello!

This issue occurs when IntelliJ/Android Studio for some reason does not automatically locate the src directory. I've never personally came across it but found a way to fix it on the internet.


To fix it, Follow these instructions:

1) Open Project Structure from the File menu (Or press F4 on Windows).

2) Go to the Modules section.

3) Select Sources.

4) Select the folder with source files in it (It'll be called src).

5) Click on the blue sources folder icon.

6) Click on Green Test Sources folder ( to add Unit test folders).


Let me know how this goes for you :)

Erin Kapoor
Erin Kapoor
412 Points

Yup, worked perfectly, thanks!