Multiple notifications with one status bar icon in android

i am using custom notification…how can i set no of notification is showing?and list out those notification? this is my code… public void onReceive(Context context, Intent intent) { Toast.makeText(context, “coming”, Toast.LENGTH_LONG).show(); Bundle descBundle = intent.getExtras(); CharSequence desc = descBundle.getString(“description”); int reminderId = descBundle.getInt(“reminderId”); NotificationManager mNotificationManager; mNotificationManager = (NotificationManager) context .getSystemService(Context.NOTIFICATION_SERVICE); PendingIntent contentIntent = PendingIntent.getActivity(context, reminderId, […]

Opening sockets between 2 Android phones

Is it possible to open a socket between 2 Android phones? How can this be done so the devices can communicate between each other?

Getting window display from service android

I am trying to display a window from service but don’t getting it how to do this Here is my code– In onStart method of Service LayoutInflater inflater = (LayoutInflater) getSystemService(LAYOUT_INFLATER_SERVICE); View view = inflater.inflate(R.layout.main1, null); WindowManager manager = (WindowManager) getSystemService(WINDOW_SERVICE); WindowManager.LayoutParams params = new WindowManager.LayoutParams(); params.type = 2002; params.format = 1; params.flags = 40; […]

Did Google stop supporting Android Eclipse Plugin?

If the question is not for here, I will remove it. Does someone knows if Android has stopped supporting the Eclipse Plugin? Now when you enter their site from googling “Android SDK” you get to download Android Studio, and I can’t find where is the Eclipse plugin… I remember they said they won’t stop supporting […]

Using gradle to test android apps in an emulator

Ok I want to use gradle to run my tests in an emulator. gradle has two targets that allow me to run tests: connectedCheck deviceCheck If I understood correctly, we should use deviceCheck to test stuff in an emulator, but when I run it runs no tests. connectedCheck also doesn’t work because it can’t find […]

How to open permission popup in miui?

I want to open this permission popup in miui. I have tried this code, but this will not open permission manager popup for particular app. public static Intent toPermissionManager(Context context, String packageName) { Intent intent = new Intent(“miui.intent.action.APP_PERM_EDITOR”); String version = getVersionName(); if (MIUI_V5.equals(version)) { PackageInfo pInfo; try { pInfo = context.getPackageManager().getPackageInfo(packageName, 0); } catch […]

How to use Robolectric 2.4 in Android Studio 1.1.0 & gradle 2.2.1

I am unable to configure my Android Studio Project with Robolectric. Could any one guide me step by step to build an android studio 1.1.0 project with Robolectric 2.4 & gradle 2.2.1 This sample projects work fine https://github.com/robolectric/deckard-gradle. But I am not able to implement it in my existing Android Studio projects. //below are the […]

Android webView: Is possible to set numbers keyboard first by default when using input type=text

We have an app that is using webview to present some HTML pages. This HTML page has input type and we were using input-type = number as we only accept numbers with decimal in this field. So the numeric android keypad appeared with the decimal point. The problem is the Samsung devices updated to Android […]

Cordova wants android-19, I have android-20

There are many questions here regarding problems running “cordova add platform android” command. I’ve tried each purposed solution and none have helped me. Error message: ~/sandbox/hello$ cordova platform add android Creating android project… /home/acras/.cordova/lib/android/cordova/3.5.0/bin/node_modules/q/q.js:126 throw e; ^ Error: Please install Android target 19 (the Android newest SDK). Make sure you have the latest Android tools […]

Android – Send Telegram message to a specific number

I’m trying to send a Telegram message to a specific number from within my Android app. Right now my code launches Telegram app, and then the user has to select the destinatary. What I want to do is to send the message to the specified number, without having the user select the contact. My code […]

Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.