My app has 2 activities:
- Activity (1) has a button to start Activity (2), this button isn't set transparent
- Activity (2) has a button that is transparent by setAlpha()
My problem is sometimes, when I back to Activity (1) from Activity (2) by pressing back button, a button of Activity (1) becomes transparent same as button of Activity (2).
I don't know why this problem can occur, please help
Please refer to this image:
https://lh4.googleusercontent.com/-gEW9RFcjpnQ/UTKSd0DSR5I/AAAAAAAAALs/P...
1- When the application is started, a splash-screen is displayed through an activity
2- Then, execution goes to the Main Activity (and splash-screen activity is finished)
3- User, through button click, can go to screen-1 or screen-2 activities.
3.1- When doing so
So I have 2 activities lets say A and B. A navigates to B, I want the activity A to be killed or make it unusable/unseen when directed from B.
so it should be like when I press the back button on B activity it should not open activity A instead it should go to the app tray.
also activity A should comeback when I clear the application data
thanks.
I have three activities: A, B and C, where A is a starting activity. When user clicks a button in activity A, activity B is started with Intent.FLAG_ACTIVITY_REORDER_TO_FRONT. In activity B user can click another button and it starts activity C also with Intent.FLAG_ACTIVITY_REORDER_TO_FRONT. Loaded activity C plays some sound.
I am going crazy trying to figure out how to store a variable someplace so when I switch to another activity then back again the variable still contains this value. I did this a while ago using shared preferences, but this was a bad solution, this was way more permanent than I needed and just not the correct way.
I have 2 different activities connected with their id #'s . When I started my activity 1 Its working however when I try to back I've get Null Pointer Exception cause of I cannot retrieve my id # in turning back activity. These are my button and activity codes , can you give any suggestion ?
I am developing a simple Android app that has a few Activities, say: A, B, C, and D.
*Activity A* is a splash screen.
I have 6 Buttons, for 1st 3 Buttons i want to start same activity and for other 3 Buttons separate new activities.
So problem arises when i click on 1st button and then the second Button which starts same activity because we can not start same activity from same activity.
So I just need to know weather the activity which i am going to start is the same activity which is running, based on that if
My problem is related to the back button and the backstack, ive got a app for reading nfc tags, so ive launch Activity A, then go for Activity B, that is declared SingleTop in the manifest.
I aproach the phone to the tags and it reads the tag, everything is working fine at this moment.
If i press the back button , it goes back to activity B,instead of going to the Activity A, and then if i press