Questions tagged [android-intent-chooser]

An Intent to choose from different app options to resolve your request.

Example of usage:

Intent intent = new Intent(Intent.ACTION_SEND);

// Always use string resources for UI text.
// This says something like "Share this photo with"
String title = getResources().getString(R.string.chooser_title);
// Create intent to show chooser
Intent chooser = Intent.createChooser(intent, title);

// Verify the intent will resolve to at least one activity
if (intent.resolveActivity(getPackageManager()) != null) {
    startActivity(chooser);
}

Reference to Android page

111 questions
1
vote
1 answer

Android intent chooser cannot have empty intent target

List targetedShareIntents = new ArrayList(); Intent shareIntent = new Intent(android.content.Intent.ACTION_SEND); shareIntent.setType("text/plain"); List resInfo = getPackageManager().queryIntentActivities(shareIntent,…
justmee
  • 355
  • 2
  • 14
1
vote
0 answers

How to load images from gallery "images"

I'm trying to load images from gallery using the following code Intent intent = new Intent(); intent.setType("image/*"); intent.setAction(Intent.ACTION_GET_CONTENT); startActivityForResult(Intent.createChooser(intent, "Select Picture"),…
1
vote
1 answer

Failure delivering result while picking image from camera but no issue when picking image from gallery

i am developing an app in which there is a button which is used to pick image either from gallery or capture image from camera. When i pick an image from gallery there is no error image shows up fine in the end but when i capture image from my…
1
vote
1 answer

data.getData() returns null in OnActvityResult while taking /Selecting Pictures from Camera and Gallery

I am developing an android app, which has a profile fragment where users can upload profile picture via taking picture or selecting from gallery. For now, everything is working fine via Activity.RESULT_OK. But the problem is the onActivityResult…
1
vote
1 answer

Storage access framework/Document tree Shows Empty Recent List

I am using Storage access framework to make the user grant write permission for Sd card. It is working fine with two of my devices running on Android lollipop and Marshmallow. But it it not working with One of my device running on Android lollipop.…
1
vote
2 answers

hide my application in intent chooser dialog when click on gmail notification in android

I want to see my application in Chooser dialog when I click any type of file or click on gmail attachment or share any file in my android device. So to achieve this functionality I used below intent filters.
1
vote
1 answer

Android: Unable to open specific folder

I have found a following code to open a specific directory: Intent intent = new Intent(Intent.ACTION_VIEW); Uri uri = Uri.parse(StaticMember.APP_DIR); intent.setDataAndType(uri, "resource/folder"); context.startActivity(intent); But now I am facing…
1
vote
1 answer

Android -- intent chooser for whatsapp and sms only

I want to create an IntentChooser who offer to share text only via SMS or WhatsApp. Here is my code to share via WhatsApp: Intent localIntent = new…
offset
  • 1,407
  • 1
  • 16
  • 34
1
vote
0 answers

data is not shared - Intent chooser on Facebook

I am trying to share data in social sited like Facebook, WhatsApp, Google+, Twitter every site is sharing data only Facebook isn't. Why facebook does not share data on their wall I am using this code below: Intent sharingIntent = new…
1
vote
1 answer

App not responding for ACTION_PICK after selecting image

I have an activity in my library project. From that activity, I am trying to get an image from library. 1 out of thousand times(metaphor), the code below works fine. But mostly, after selecting an image , application gets stuck at black screen. …
BST Kaal
  • 2,993
  • 6
  • 34
  • 52
1
vote
1 answer

User select image from gallery or from custom Camera and not Camera app for image

I would like the user to be able to click on a button and have the option of selecting the gallery or similar apps or a camera activity I have in my app not the build-in one . I read the related answers here and here . However, I don't want to…
dylan7
  • 803
  • 1
  • 10
  • 22
1
vote
0 answers

Android, how does "Always Open With" save a user's preference

When application X fires an implicit Search intent and user decides to "Always Open with App Y", I am wondering what is being saved? Are all Search Intents open with app Y? Are only Search Intents coming from app X opened with app Y? Are only…
mmilleruva
  • 2,110
  • 18
  • 20
0
votes
0 answers

Send text with text link with Intent.ACTION_SEND, link is missing in Gmail app

fun shareProduct(context: Context) { Intent(Intent.ACTION_SEND).apply { type = "text/html" putExtra(Intent.EXTRA_SUBJECT, "Test") putExtra( Intent.EXTRA_TEXT, fromHtml("Visit
user924
  • 8,146
  • 7
  • 57
  • 139
0
votes
1 answer

How to show all E-mail applications in a chooser in Android?

I need to show an E-mail chooser with all installed E-mail apps to the user to select an App and check E-mails (not compose). I'm using the below code. val intent =…
0
votes
1 answer

Intent filter not working for "geo:" scheme in Android

I have noticed that when someone shares a location in WhatsApp using WhatsApp location share feature, tapping on the location opens up application chooser which included both GMAP and Uber. Initially, it looked like it was something like the…