title: Android Studio 1.0.2 new project - Cannot resolve symbol 'ActionBarActivity'
body: <p>I’m very confused. Today I just reinstalled Android Studio Version 1.0.2 (and the Android SDK) because I had some problems yesterday when I created a new project. I hoped that I could solve them by just reinstall everything, but actually the problem still exists and I don’t know how to solve it.</p>
  
  <p>After I created a new project in Android Studio and switch to my MainActivity (I didn't changed anything in one of the files), I always get the following errors displayed in the file.</p>
  
  <p><strong>MainActivity.class:</strong></p>
  
  <pre><code>package com.android.testapplication;
  
  import android.support.v7.app.ActionBarActivity;
  import android.os.Bundle;
  import android.view.Menu;
  import android.view.MenuItem;
  
  
  public class MainActivity extends ActionBarActivity {
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main);
      }
  
  
      @Override
      public boolean onCreateOptionsMenu(Menu menu) {
          // Inflate the menu; this adds items to the action bar if it is present.
          getMenuInflater().inflate(R.menu.menu_main, menu);
          return true;
      }
  
      @Override
      public boolean onOptionsItemSelected(MenuItem item) {
          // Handle action bar item clicks here. The action bar will
          // automatically handle clicks on the Home/Up button, so long
          // as you specify a parent activity in AndroidManifest.xml.
          int id = item.getItemId();
  
          //noinspection SimplifiableIfStatement
          if (id == R.id.action_settings) {
              return true;
          }
  
          return super.onOptionsItemSelected(item);
      }
  }
  </code></pre>
  
  <p><strong>Errors:</strong></p>
  
  <ul>
  <li>Cannot resolve symbol 'ActionBarActivity'</li>
  <li>Cannot resolve method 'onCreate(android.os.Bundle)'</li>
  <li>Cannot resolve method 'setContentView(int)'</li>
  <li>Cannot resolve method 'getMenuInflater()'</li>
  <li>Cannot resolve method 'setContentView(int)'</li>
  <li>Cannot resolve method 'onOptionsItemSelected(android.view.MenuItem)'</li>
  </ul>
  
  <p><strong>Project: build.gradle</strong></p>
  
  <pre><code>buildscript {
      repositories {
          jcenter()
      }
      dependencies {
          classpath 'com.android.tools.build:gradle:1.0.0'
  
          // NOTE: Do not place your application dependencies here; they belong
          // in the individual module build.gradle files
      }
  }
  
  allprojects {
      repositories {
          jcenter()
      }
  }
  </code></pre>
  
  <p><strong>Module: build.gradle</strong></p>
  
  <pre><code>android {
      compileSdkVersion 21
      buildToolsVersion "21.1.2"
  
      defaultConfig {
          applicationId "com.android.testapplication"
          minSdkVersion 14
          targetSdkVersion 21
          versionCode 1
          versionName "1.0"
      }
      buildTypes {
          release {
              minifyEnabled false
              proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
          }
      }
  }
  
  dependencies {
      compile fileTree(dir: 'libs', include: ['*.jar'])
      compile 'com.android.support:appcompat-v7:21.0.3'
  }
  </code></pre>
  
  <p>I already rebuild and cleaned my project and <code>'Sync Project with Gradle Files'</code> but none of them fixed my issues.</p>
  
  <p>The funny thing is, that I can compile and run my project on my smartphone…</p>
  
  <p>PS: I guess it seems to be a gradle issue, because whenever I add a new library such as <code>'com.google.android.gms:play-services:6.5.87'</code> and then try to import it <code>'import com.google.android.gms.gcm.GoogleCloudMessaging;'</code>. I also get the <code>'Cannot resolve symbol…'</code> error displayed. I didn’t complied it with the GCM Service…</p>
  
  <p>Thanks for your help in advance :)</p>