Skip to content
keith yau edited this page Dec 3, 2013 · 12 revisions

Since android studio currently not support import modules from UI, we can only do it with gradle settings.

  1. Create a new project
  2. Copy drupalForAndroidSDK module in this SDK to your project directory
  3. at settings.gradle, add ':DrupalForAndroidSDK' -> include ':YourApplicationName', ':DrupalForAndroidSDK'
  4. Click the Sync gradle project button
  5. current Android Studio 0.3.6 will modify your build.gradle file in DrupalForAndroidSDK, so you need to modify it back to the SDK provided one by copy and paste the build.gradle again
  6. Copy and paste demo source code to your Application from drupalForAndroidSDKDemo
  7. Import required library by alt+enter
  8. Add <uses-permission android:name="android.permission.INTERNET"/> to your AndroidManifest.xml
  9. Modify the Android version you are using like below

compileSdkVersion 19 buildToolsVersion "19.0.0" defaultConfig { minSdkVersion 14 targetSdkVersion 19 }

Compile your project again and done !

Clone this wiki locally