Tag: android-intent

animated transition between an activity and another

I state that i’m not very experienced in android, and I would like to understand, perhaps with some tutorial, how to implement any scrolling animation between one activity and another. I hope in your help

Sending ACTION_CALL Intent in Android containing hash # sign

I am having the problem that the hash sign is truncated. Does anybody know a solution? using unicode or %23 is not working in my case. Now the number that is dialed is *101 String uri = “tel:” + “*101#”; //String uri = “tel:” + “*101\u0023”; Intent intent; intent = new Intent(Intent.ACTION_CALL, Uri.parse(uri));

Android NFC Intents are not starting my activity

I am trying to write a simple application to interact with NFC tags, but I cant seem to get my phone to do anything but trigger the default NFC tag app. I really just want to be able to intercept any tag I scan, determine if it has some data on it, and take action […]

How do I create an Intent that opens the Call Log Activity?

I want to create an Intent that opens the screen showing the call logs of the current device? How would I specify such an Intent?

Notification opens activity, back button pressed, main activity is opened?

The best way I can describe my problem is like this: A notification is created at boot (with a BroadcastReceiver). My app main activity is opened and the home button is pressed (the app is still running in the background until the system closes it). I pull down the status bar and press on the […]

Android – Registering a broadcast receiver for two intents?

I was wondering is it possible to register a broadcast receiver to receive two intents? My code is as follows: sipRegistrationListener = new BroadcastReceiver(){ @Override public void onReceive(Context context, Intent intent) { String action = intent.getAction(); if (SIPEngine.SIP_REGISTERED_INTENT.equals(action)){ Log.d(“SETTINGS “, “Got REGISTERED action”); } if (SIPEngine.SIP_UNREGISTERED_INTENT.equals(action)){ Log.d(“SETTINGS “, “Got UNREGISTERED action”); } } }; context.registerReceiver(sipRegistrationListener, […]

ACTION_SEND force sending with email

every time i create an action for sending an email from my app, it prompts to many options including a QR client… Is there a way to force sending via email clients only? Code for sending the email String rec[] = { owner.email }; i = new Intent(Intent.ACTION_SEND); i.setType(“text/plain”); i.putExtra(android.content.Intent.EXTRA_EMAIL, rec); i.putExtra(android.content.Intent.EXTRA_SUBJECT, “RE: ” + […]

YouTube intent, error 400

I found that I can start a YouTube video in stock YouTube player this way: Intent i = new Intent(Intent.ACTION_VIEW, Uri.parse(“vnd.youtube:U79wVTdnMpw”)); startActivity(i); But it doesn’t work. The YouTube player is started, but I get an error: There was a problem with the network [400] I have updated the YouTube app but nothing changes. I am […]

How to get data from other activity in android?

I have two activities such as Activity A and B and I’m trying to pass two different strings from A to B using Bundle and startActivity(intent). Like that: Intent intent = new Intent(A.this, B.class); Bundle bundle = new Bundle(); bundle.putString(“vidoedetails”, filedetails); //bundle.putString(“videoname”, filename); intent.putExtras(bundle); //intent.putExtra(“videofilename”, filename); //intent.putExtra(“vidoefiledetails”, filedetails); startActivity(intent); And in class B I’m using […]

How to implement onBackPressed() & intents in fragment?

I know that onBackPressed() is a method in activity but, I want to use the functionality in fragments such that when back button is pressed, it gets redirected to another activity via Intent. Is there any solution to this ? public class News_Events_fragment extends Fragment { ProgressDialog pd; ListView lv1; SharedPreferences sharedPreferences = null; int […]

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