Menu
  • HOME
  • TAGS

java.util.zip.ZipException: duplicate entry

android,android-studio,android-gradle,zxing,android-developer-api

Make sure you have the latest build toolds and sdk from the SDK manager. I have converted those jars to Gradle dependencies. build.gradle: // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { repositories { jcenter() maven { url 'http://ksoap2-android.googlecode.com/svn/m2-repo' } // <-- added...

Android SDK API 22 to API 21

android-developer-api

No they, can exist in parallel. You don't need to uninstall API 22 tools and files.

Turning off ADB over WiFi through ADB shell?

android,shell,adb,android-developer-api

adbd is the adb daemon that runs on your devices, awaiting connection. issuing stop adbd should kill it - you may have to run this as root, should stop adb on the device, and disconnect your active shell. edit just tried this and it worked for me, running cyanogenmod. using...

How to access files in file:///android_assets/?

android,android-assets,android-developer-api

That folder is inside the .APK, therefore you need to find it, download it into your computer and unzip it. Yes, you can do it trough DDMS or trough adb, but you probably need to have the device rooted first....

How to read a large json from a text file in android app?

java,android,inputstream,fileinputstream,android-developer-api

For big json files you should use SAX parser and not DOM. For example JsonReader. DOM (“Document Object Model”) loads the entire content into memory and permits the developer to query the data as they wish. SAX presents the data as a stream: the developer waits for their desired pieces...

JSONObject return type

java,android,json,android-developer-api

public JSONObject lastSub(String username) throws ClientProtocolException, IOException, JSONException { StringBuilder url = new StringBuilder(URL); url.append(username); HttpGet get = new HttpGet(url.toString()); HttpResponse r = client.execute(get); //httpStuff.setText("xxx"); int status = r.getStatusLine().getStatusCode(); if(status == 200) { HttpEntity e = r.getEntity(); String data = EntityUtils.toString(e); JSONObject last = new JSONObject(data).getJSONArray("result").getJSONObject(0); return last; } else...

How to enable Non market application in Managed Profile (Android 5.0) programmatically

android-5.0-lollipop,device-policy-manager,android-developer-api

After searching for many days I found that currently google has not provided any API/ methods to enable non-market application in managed profile.

AndroidKeystore on 4.1 API

android,security,android-keystore,android-developer-api

I finally found a working solution. For Android 4.x there is the Credential Storage service which can hold various secrets. The best description I found so far is here http://nelenkov.blogspot.de/2012/05/storing-application-secrets-in-androids.html...

Is it possible to connect wear emulator to android ICS 4.0 device?[Solved]

android,android-wear,android-developer-api

No, Android Wear needs API 18 - Android 4.3.

How to click song list (Now Playing activity) to playing without (Music Preview) startActivity

java,android,android-intent,android-activity,android-developer-api

You could use a BroadcastReceiver for this. private final BroadcastReceiver mHandleMessageReceiver = new BroadcastReceiver(){ @Override public void onReceive(Context context, Intent intent) { //Get all your music data from the intent String position = intent.getStringExtra("pos"); ... } }; Register this BroadcastReciever with an Intent in your NowPlayingActivity's onCreate() like this, registerReceiver(mHandleMessageReceiver,...

MonkeyRunner script go to 'Developer options' then check 'Stay Awake' but is not recorded

android,settings,monkeyrunner,android-developer-api

The problem is coming from MonkeyRunner. I recomend to use @dtmilano tool AndroidVIewClient that is easier to use than MonkeyRunner. This tool solved my problem.

SDK Manager in Android studio not opening when clicked on inside Android studio

android,windows,sdk,32-bit,android-developer-api

This happened to me too after I updated Android Studio from a beta version to 1.0. After trying all sorts of things including uninstalling and reinstalling, what finally worked for me was to modify find_java.bat to be hard-coded for 32-bit as described in this message: https://code.google.com/p/android/issues/detail?id=82603 I just modified it...