Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

cannot resolve android symbol - android app - intelliJ

I am using intellij-idea to develop android app. I created a project with an android module, but none of these :

import android.app.Activity;
import android.os.Bundle;

are recognized, I get cannot resolve android symbol. I googled this issue but none of the remarks I found there seems to debugg my problem

like image 617
user1611830 Avatar asked Jun 23 '13 16:06

user1611830


1 Answers

What you should do is,

1.  Select your android project
2.  press ctrl +alt + shift + S
3.  Select SDK from the project settings
4.  Check the files under the class path tab
5.  There must be android.jar ,res ,annotations.jar
Probably there should be missed one or several files in step 5.
Then,
6.  Go to Android SDK home path field and add your SDK folder again
files  even though  you have all the jars and still  you are getting the error ,then remove all the jars from the class path and add them again ( like in step 6).
7.  Build menu -Rebuild  your  project.

Now your errors should disappear.

like image 114
Dilini Avatar answered Sep 30 '22 21:09

Dilini