Questions tagged [extras]
113 questions
0
votes
1 answer
Android getSharedPreferences startActivityForResult intermittent error
I have a game whose main activity calls three other activities using startActivityForResult -- the first (SignInActivity) returns a user name, or allows the creation of a new one; the second (LevelChooser) uses getSharedPreferences to find a…

Richard Buck
- 21
- 5
0
votes
1 answer
My receiver don't receive the intent
I've this problem: i set the alarmManager with intent and pendingintent, if some conditions is satisfied, put some extras in the intent.
The problem is that my receiver don't read my extras:
Set alarmManager in MainActivity:
AlarmManager am =…

BeginnerNub
- 15
- 1
- 4
0
votes
0 answers
Some troubles with extras
I am trying to put and get integer value from one activity to second, but I get errors. Have no idea why this is happening. Second activity also can not start because of this error.
Here is first activity:
@Override
protected void onCreate(Bundle…

iascendk
- 1
0
votes
0 answers
Android Intent-Extras are not accessed
So I've been trying to pass an Extra (a single String) from one Activity to another via an Intent. In the following Activity, it is supposed to get the String from the last intent and use it as a condition for another change in Activity.
I do not…
0
votes
2 answers
Intent not extracting extra
I have this code:
protected void onListItemClick(ListView l, View v, int position, long id) {
super.onListItemClick(l, v, position, id);
Log.i(TAG, "The id of the selected note is " + id);
Intent editNote = new Intent(this,…

Mohit Deshpande
- 53,877
- 76
- 193
- 251
0
votes
1 answer
All extras Strings take the value of the last one put into the bundle
I am working on an android app where the user fills in one activity, then another one and a word docx report is generated.
I am using extras to pass Strings from the first activity to the second one.
My problem is that all my Strings have the…

Stone Edge
- 52
- 11
0
votes
1 answer
How to access value of an extra
I want to access the extras contained in the BluetoothDevice.ACTION_FOUND, for example if i want to access the value containd in BluetoothDevice.EXTRA_CLASS, I should use it as shown below in the code, but when I display the value of the variable…

rmaik
- 1,076
- 3
- 15
- 48
0
votes
3 answers
Image passing from one activity to another using extras
Would anyone tell me how to pass images from one activity to another activity using extras (the idea is). I am displaying a set of images in activity1 as a horizontal scroll view. When I click on an image it should be displayed in another activity …

mohammed nathar
- 190
- 1
- 12
0
votes
1 answer
How to send/receive extras to Fragments in SwipeView Activity
I am trying to use the Swipe View with Tabs in Android and i need to pass some variables to the fragments of the tabs to show a customized content, my problem is that I always have the bundle to 0 so I think I am doing something wrong with the…
0
votes
2 answers
Fragment returning null from intent
So i made a bunch of 4 buttons , put an intent to each of them . They all navigate to the same Fragment class . But their extras are different, so if button1 was clicked , Fragment would open and do a certain action , if button2 was clicked ,…

Metalloid66
- 119
- 10
0
votes
1 answer
Intents crashing in simple android game
I am making a simple game for android, however as I am kind of beginner sometimes I have some problems with basic things and errors in my code. I dont know what is wrong with that code but it seems to crash when I press back button and does not…

Beda
- 61
- 3
- 12
0
votes
3 answers
How to use put and get extra in intents
I have two classes, the first one within the onclick i have ;
Intent myIntent = new Intent(getApplicationContext(), PlayGame.class);
myIntent.putExtra("gameWord", Word.getRandomWord().toUpperCase());
startActivity(myIntent);
…

NWall
- 13
- 7
0
votes
1 answer
Prepare extras for next Activity launch
I want to set some Extras for the next startup of an activity. However, I want the user to start the activity, i don't want to start it programatically with startActivity();
It should also work if the target activity is currently killed.
Could you…
user2945914
0
votes
1 answer
How i can get a string with a bundle and put this string into a ListView using an adapter?
Sorry for my english, my question is this:
The class adapter for the listview wont let me use a bundle to get extras and use thIS extras(Strings) in this line code .setText(getString("...."));.
Example:
I want use this to set the text in the…

lukskb
- 1
- 1
0
votes
3 answers
Eclipse: How to add Google Play Services to Extras in Android SDK Manager?
Please see the picture.
I know that Google Play Services must be here, but it is not here.
How can I add GooglePlayServices to Eclipse?

bask0xff
- 145
- 4
- 13