Android-intent Questions
Ad
How to start a foreground service from a respository
I have a single activity kotlin-based app that starts a foreground service with:
Intent is not working inside fragment to open Activity
I'm trying to use intent inside placeholderfragment class of tabactivity's fragment to open next activity. here is my code:
Why does intent.getAction() in onReceive of my BroadcastReceiver returns null?
I want to trigger onreceive function of broadcastreceiver at a particular clock time. the fragment that creates the intentfilter and/or registers
The activity is showing blank when it is opened from the Fragment Class
I have a fragment activity which is a listview. when the user clicks the an item from the listview it opens another activity. the new activity is
How do I use intent from arrayAdapter to go into a third activity?
I am almost done with this project, and the code is janky, but i am trying to pass data through the arrayadapter to the third activity, but even
Pass API object via Intent to Service?
I'm trying to send an object created from the spotify api (a spotifyappremote instance) from my mainactivity class to a backgroundservice
I don't go next Activity?
I faced too many problems in this project, i don't intent this data, when it's finished it's going to the homeactivity, not
Create Intent, but leave BottomAppBar visible
I have a standard android app with a bottomappbar, 3 fragments/tabs, a floating action button which opens an intent. the intent occupies the whole
How to set custom ringtone for a specific contact?
I want to set a ringtone for a specific contact. i know how to get contact and set a ringtone for phone but how i can set custom ringtone for a
Different activitys intent - same List
I have an array list values. in recyclerview this list open same activity for all items. i wish in a different position (few items) to open a
Ad
Getting ResourceNotFoundException despite passing the item ID
I'm building an app where the user can create entries through a designated activity and edit entries in that same activity by long clicking an
Storage Access Framework - Permanent permission grant fails on user-selected folder
I am trying to test storage access framework in a sample activity. the goal is to get a permanent read/write permission on a folder uri the user
ACTION_GET_CONTENT Picking Document from Downloads returns null
I am working on pdf pick and upload to server. below code crashed when file picked from downloads. and works fine if file choose from any other
Attach image using Intent.ACTION_SEND
I'm trying to attach an image using different applications with the following code: val sendintent = intent(intent.action_send)
Call MainActivity from module
I have some android modules which all depend on the same library module, for business logic. com.example.api ->
Layout not showing up when using intent to start new activity
I have a fragment class with 6 hard-coded cardviews. i want the user to be able to click on them and it open up another activity. each opens to
How can I pass content using Intent and OnActivityResult?
My problem is: i have 2 classes: firstactivity.java secondactivity.java when i click on fab
Android deep link always opening in the Browser first and then the correct activity
On android version 5.0 we are using deep links since app links work only from android 6.0 onwards. we are facing an issue on these devices: when
TransactionTooLargeException on API 28+ when sharing bitmap despite using Intent.EXTRA_STREAM
I am trying to share a bitmap via an intent to all apps that can handle images.despite having follwed the instructions in several stack overflow
Passing values through activities
I made some app, that you can create account with it, and it's passing username and his password, although username get's passed without any
App crash when trying to move intent to another adapter
So i have two adapter class for recyclerview. i want the imageview inside one adapter class to display the other adapter class i already
Ad
Problem in logout for my app. app keeps on crashing
I'm trying to make a logout for my project. i want that whenever i click to logout image i intent to my login page again. for login i'm using
How can I pass parameters between two Activity but one must only support the first one
I have an activity that very quickly has to process data and then return to the previous activity, i give an example: i have a mainactivity class
Create simple WebView with action.VIEW
Hi i've create a simple link browser, but i lost last update to open external url. this is the androidmanifest.xml
Start Another Class From adapter Using Intent?
I want to use intent and want to move to another viewpager class and i am using the intent to do this like private void
Send data to activity when clicked on notification?
I am opening a activity when notification is clicked . notification is activated from a service class .i want to send data to new activity opened
Not able to intent to next layout
I'm working on my project and i created an interface of my app.
How to start activity in adapter
What i am trying to do is start an activity in my adapter but it seems that i'm getting an error on my other adapter.
Why can't doInbackground method have empty body?
I have a class that extends asynctask. i pass in a list of cholesterol monitors and create the fragment in
Unsafe use of a nullable receiver type Bundle? android app will compile with warning but instantly crashes
I am new to kotlin and android programming, and it seems like this language is moving rather quick without some backwads capabilities.
Intent to open default camera in square mode
I can open a camera from intent by this: intent takepictureintent = new intent(mediastore.action_image_capture);
How to send data from fragment to Activity in Android
In my application i want use fragment and activity and i want startactivity from this fragment
Ad
Android How to set Flags global for all Activities
I have the problem that currently every time i start a new activity for example like this: intent exchangedetail = new
Editing Image using Image Uri
I have a image uri and i want to edit that image and obtain the new image uri. after some searching i found this piece of code and tries to
How to create folder in internal storage and save captured image
I want to capture image and save it to specific folder in internal storage. currently i am able to open intent and get thumbnail of captured
Could not execute method for android:onClick when trying send an image in email
I'm writing an app that sends images in email, but somehow i get this error. can pls somebody tell me what did i wrong? i got all
How to set an Alarm Using an Intent Selecting the full date of the alarm (including day, month)
So i'm trying to add a feature in my app to launch the alarm clock and set one, i tried it using the usual code: intent i = new
Cannot Figure Out Why Intent is not Being Passed Back to Previous Activity
I have been trying to track down why my leagueid is not being passed back to the previous activity for sometime now and i cannot seem to figure it
getIntent().getStringExtra("name") returns null
I'm currently making a "battleships" game for my school project. first off, i put strings named "hoststate" and "key" in the intent extra and
Start an activity without re-load activity / layout before
I want to start a new activity when you press an entry. the current activity is a listview with items that load automatically when
Going back few activities without destroying the bottom one
I did a simple sample with 3 activities: activitya activityb
Exception when starting activity android.os.TransactionTooLargeException: data parcel size
Creating intent with a large amount of data in extras public static intent createintent(context context, list<photoitem>
How to pass and retrieve a two dimesional Array as intent
I need to pass a 2d array as an intent onto another activity. this code works for sending the 2d array, the problem is retrieving it in
Ad
How do I determine the MimeType that was used by GMail to pass a file that was received by my app?
I have an app that's supposed to handle my custom data-type .xyz. i'm currently using the intent filter:
Why don't match the path?
Hy i have a problem, i try to save a file to custom directory, but doesn't work. first of all i choosen the downloads directory,
What exactly is intent.resolveActivity(getPackageManager()) doing?
I'm going through the
Wrong Activity is getting openned on clicking Notification
After clicking on notification, wrong activity is being oppended - main application activity, but not my goal activity - nearphotoactivity.
android.content.Context.getPackageName()' on a null object reference, when trying to access a method in an activity through a java class
I am running a basic face detection app in real time, and im counting the number of times it detects a face in the facedetectionprocessor.java
How to share Videos to any app using Intent?
Issue: what happens is after sharing the video when i launch the app to check the shared video it shows me error of
User press image button to open a URL without a new window appearing
How do i make it so that the user presses the image button and a url link gets pressed without opening a new window? private class
A Bundle is null after returning back from another activity
I have a problem with a bundle. i have 2 activities(with fragments), and i want to store data in a fragment feedlistfragment. when
How PendingIntent triggers intent?
For example, we have. pendingintent pi= pendingintent.getactivity(context, requestcode, intent, flag); when we
how to not lose any data in the first activity when you use intent
Okay lets say we have 2 activities such as mainactivity(ma) and secondactivity(sa) ma is the user interface that takes name,number from the user.
How to send an object from imported package to another Activty
I've made an activity (a) that recovers a list<event> from google calendar api in an asynctask, and then sends it from (a) to
Ad
Navigation component with instant/(dynamic-)feature modules
I'm trying to implement the new navigation component with dynamic features so the structure looks like this: app
How to delete a file using the path
I'm building an app that allows the user to save the bitmap or share it without saving it. the 2nd functionality doesn't quite work. i
Activity result code always 0 (cancel) when there is two or more activities to handle intent
I have a problem, when i startactivityforresult to take picure, resultcode is always activity.result_canceled (0) if there is two or more camera
How to check the internet connection continuously while app is running
I have created code which checks the internet connection at the start but i want it to keep checking for internet connection in the background and
Keep activity while the app is not on top of screen
I got a problem with multitasking, its probably a stupid question but after looking for hours an answer, i dont know how to do it everybody seems
Send data based on Button in Android Studio
I have 2 activities. 1st activity has got 3 buttons. these buttons have text as c1, c2 and c3. for example, if i click button2, second activity
Starting intent with adb opens complete with dialog
I made a simple app for android and it works fine, however when i open an activity with adb the emulator displays a complete with dialogue:
Is there way to share *.json file via Intent or something else?
In my app i need to share *.json file to other app (messenger, google disk, etc). how can i do this via intent or something else? but when
Why does Intent.ACTION_SENDTO includes the app as an option
My navigation drawer includes an option to contact the developer via email. to do this i've included code in accordance with the documentation.
Open URL in Firefox for Android using Intent
Normally, we can open a url in chrome
android app crashed on loading new intent
I am making an android app were you can practice multiplication. you select an number from 1 trough 10 and then you get 10 questions. after those
Ad
How to stop spending broadcast in Android?
I have an android project which is sending a broadcast every second and am trying to figure out how to stop it after a click. my broadcast
TelephonyManager.EXTRA_INCOMING_NUMBER is null in android 9
I am not able to get the caller phone number using telephonymanager.extra_incoming_number in android 9 devices. its always null. i have added the
AdView banner changes position with keyboard after returning to Main Activity from Intent
My adview banner is constraint to bottom of parent. there is no issue with it so long as i do not start my intent sqlview. after calling sqlview
How to finish the Ads_Fullscreen Activity in 8 seconds and lunch the MainActivity after wards?
Two situation for splash screen if ads is enable then splash screen time will be 2 seconds and ads_fullscreen time will be 8
Encapsulate a method that start an activity, outside an activity
I am trying to create a method that authentificates a google user on firebase. i am using this method in 3 different activities, and i
Shared Element Transition overloapping BottomNavigationView
I used sharedelement transition to go detailsactivity in my recyclerview's onitemclick method. but when the item which is at the bottom is clicked
How to generate Product link?
I want share url of product, product name to some user using either what's app or facebook etc.when user clicks on that product same product page
How to add on click functionality to recycler view?
This is my adapter where i had added onclicklistener in myviewholder. i want to execute onclick functionality on the card view and get the
Send list of object from a web service to another activity
I want to send a list of objects back from a web service in an activity to another activity but i get nullpointerexception. i
How to share data once an activity has started from another function?
I would like know how to send a command to an activity wich has started from inside another function. more precisely i want to send a pause intent
Cannot figure out how to create the cancel button for ringing alarm
I am having trouble to stop the alarm from ringing even after i have pressed the stopalarm button. i cannot figure out how to get access to the
Ad
Parsing JSON to Parcelable objects to send Parcelable object to another Activity in Android
I wanted to pass the json data coming response from post request done on an api. i have created sharing class which implements
Does importing a non-serializable class in a class that implements Serializable breaks Serialization?
Does importing a non-serializable class in a class that implements serializable breaks serialization? import
Android: How to switch to Activity that has already been created
I'm new to android programming. what i want to do is to swith to an another activity that has already been created. suppose i started activity b
How to get subtitle from firebase push notification
I am getting push notification in this format from server. { title: messagetitle, body:
how to launch amazon prime video app on android TV using Intent
I'm trying to launch amazon prime for tv app
How to exit on double back press with showing the snackbar dialogue of exit?
I wanted to make a snackbar dialog on double press to exit...(java) requested with these on 1st time
How to set multiple image in multiple imageview
I am new to programming and android. i'm building an app that allows users to upload multiple images,i am using two image view, pic from camera to
Android - Adding an Intent to a notification
I'm new on android development and i still don't understand intent very well. here i'm using firebase to create notifications, i add an intent to
Is there a way to keep permanent access to resources exposed with FileProvider across multiple app launches on Android
So basically, my app receives external content:// uris exposed with android
Is it possible to override the power off action?
I'm trying to modify or override the functionality of power off menu button in android (not the button to screen on / off). i want to
Get Activity's 1 Intent extras from Activity's 2 static fragment
I have the following scenario. i use an intent to go from selectrecipeactivity to recipestepsactivity. i use a bundle to
Ad
Retrieveing saved address from phonebook by using a pick intent
I want to pick a contact from phone book using intent and selected contact should also contain respective city and state (if saved by user).
OnActivityResult not getting called in Fragment where intent pass from adapter class
So in my adapter class, i would like to allow user to capture image fun dispatchtakepictureintent() { try {
Get SharedPreferences inside an intent
My problem is that i need information from my shared preferences in an intent. everytime the intent that a wireless
Couldn't send SMS from Activity , says "could not start conversation"
This code was working, it opens the default sms app and message appears in textbox , ready to enter number and send, but now this code doesn't
Custom action chooser on a FAB button click
I'd like to display kind of custom chooser (similar to the share intent chooser) on a fab button click event. the thing is that it should
Intent problem with Map activity - how to fix that?
I need to create an activity that must be pass next week. the activity is to make a home page with 2 button (camera and map) meaning i have to use
Java nested parcelable, can't initialize an array
Okay, i have read through nearly every single parcelable question on stack overflow and have tried a number of solutions in order to solve this
FragmentActivity interact with Fragment type GoogleMap
Question, how can fragmentactivity (call it a) interact with another fragment (call it b), and b is dependent on fragment (call
SecurityException: Permission Denial: While launching Activity via explicit intent
I was reading about declaring
What are typical use cases for multithreading vs services?
Since threads persist past the lifetime of the activity that spawn them, i can just put whatever background work i need to do on handlerthreads
Oreo - Prevent ACTION_GET_CONTENT from using built-in Files app
My app reads information from a file selected by the user (then does weird and wonderful things with it!). to make this simple, the "file
Ad
Access Room database to update widget in onHandleIntent method of IntentService
I have a widget which i want to update every time i update my database and want to show the content from the database on the widget even when the
getStringExtra return NULL
Here is my code, the first activity: final string countryname = name.gettext().tostring(); wikibutton.settext("wiki "+
Ad
Blog Categories
Ad