0

I am trying to use action bar in android 2.2, but i cant find build.gradle in my project? Can anybody help me please?

Link is here:http://developer.android.com/tools/support-library/setup.html

Make sure you have downloaded the Android Support Repository using the SDK Manager.
**Open the build.gradle file for your application.**
Add the support library feature project identifier to the dependencies section. For example, to include the appcompat project add compile "com.android.support:appcompat-v7:18.0.+" to the dependencies section, as shown in the following example:
dependencies {
    ...
    compile "com.android.support:appcompat-v7:18.0.+"
}
Anson VanDoren
  • 956
  • 1
  • 12
  • 22
DuyguK
  • 4,250
  • 9
  • 33
  • 46

1 Answers1

0

In Android Studio you can search for a file. So, in Windows try ctrl + shift + n or in Mac try cmd + shift + o. Then type build.gradle and the file will show up in the search results. Look for the block dependencies and add the support library there, like so

 dependencies {
     ...
     compile 'com.android.support:support-v4:19.0.0'
 }

If you want to know more about gradle check the Android documentation.

Joao Sousa
  • 4,055
  • 1
  • 26
  • 29