Questions tagged as 'android-activity'

1
answer

How to open an activity from a calculation?

I'm a layman in android studio and need to do a program on a BMI calculation. The idea is simple, in the first activity he asks for his weight and his height, after that he must make the account of the imc (imc = weight / height²) and if the res...
asked by 23.09.2017 / 20:38
1
answer

How do I click items in a list in Android Studio?

For the time being my code is like this? how to implement the click of the list items the click would be to open a new screen ListView lista_teste = (ListView)findViewById(R.id.lista_teste); String[] dados = new String[]{"xxxxx","xxxx"...
asked by 06.10.2017 / 17:14
1
answer

Passing parameter to another Android activity

I created a QRCode and made it as soon as it generated the value, it was shown on the screen and I would have the option to say ok or just quit, I would like it when I clicked on Ok it was thrown to another activity where inside of this a...
asked by 18.09.2017 / 15:42
1
answer

Object list for another activity

I'm trying to save a list of objects with sharedpreference and gson. And the idea is that I can load this list into a ListView, I did the tests and when it goes to listVIew it loads only the packages, photos: Choose Products - FINAL SCREEN...
asked by 22.09.2017 / 18:23
1
answer

Navigation Activity

I would like some help when I open my Navigation Activity after I log in so: ButIwishitwasalreadycalledwithoneofthepagesmarkedlikethis: activity_main_drawer.xml<?xmlversion="1.0" encoding="utf-8"?> <menu xmlns:android="http://schemas.a...
asked by 14.07.2017 / 15:35
1
answer

Unable to start activity ComponentInfo {}: java.lang.NullPointerException

I'm having difficulty finding the solution to this problem, in the code I want to move from the activity "MainActivity" to "PlantaList", but at the time of testing the application on the virtual machine the app closes after this action and the t...
asked by 17.06.2017 / 22:28
1
answer

How to put a title in the fragment?

I have the following code, which calls a fragment, in the ScheduleSearch activity: @Override public void openFragment(int home, boolean search, boolean changeClickDirection) { if (home == 0) { PlaceListScheduleFragment fragment = n...
asked by 05.05.2017 / 15:12
1
answer

The string did not come empty then call another Android screen

The goal of the Android app is as follows; I statically loaded a list of people into the Person entity, so the class screen_activity would identify if the list would come empty or filled, if it were empty it would call main.xml screen if it w...
asked by 30.04.2017 / 18:27
1
answer

Pass data from Fragments to Activity

I have an application with a main activity and inside it there is a viewpager with fragments generated by a list and a floating button. What I want is that by clicking this button I can return data of all fragments generated for this activity. B...
asked by 15.05.2017 / 03:41
1
answer

EditText with same size Android

I would like to leave my components <EditText/> the same size but I can not. <?xmlversion="1.0" encoding="utf-8"?> <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_pare...
asked by 30.08.2017 / 03:00