Questions tagged as 'android-fragment'

1
answer

why after closing a fragment the main activity marked me error app?

Oddly enough, I have a dialog fragment that I close with dismiss (), but this fragment I display info (coordinates, street, city and country), I put code and the error that marks: Attempt to invoke virtual method 'java.lang.String android.cont...
asked by 17.01.2017 / 02:06
1
answer

Update Fragment?

I have a gallery that is divided into two sections, which I use two Tab to divide, use ViewPager . Here is my code of the class Pager and therefore use Fragments , I have impliementados several methods delete image take...
asked by 23.09.2016 / 17:05
1
answer

Open a fragment from another fragment of different activity

I have a question In this code that I currently have, located in a fragment contains a "swich case" that opens a different activity, now what I did is create another an activity 2 which loads 12 fragments with a viewPager, which would replace th...
asked by 09.08.2017 / 07:06
2
answers

Passing data from a broadcastreceiver to an activity

I have the following problem. I'm trying to send data from BroadcastReceiver to an activity. in the onRecive () I have: intent = new Intent(context, MainActivity.class); intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); intent.putExtra("valo...
asked by 13.06.2017 / 21:28
1
answer

RecyclerView in Fragment

here with another question I am doing an Android application and the problem is that when calling the RecyclerView I get this error:    E / RecyclerView: No adapter attached; skipping layout But I do not know why I get this error and only...
asked by 06.03.2017 / 05:19
1
answer

Save status of a fragment

Good, I have the doubt that every Android programmer had in the beginning xD I have an activity in which at the beginning a fragment is loaded in it, then that fragment will change for another one depending on a Drawermenu . Well, so fa...
asked by 01.12.2016 / 13:19
1
answer

RecyclerView duplicating items when starting the application

When starting the fragment and loading the recyclerview, it duplicates the items. private void loadData() { if (categoriaList.size() > 0) categoriaList.clear(); miprogress.setVisibility(View.VISIBLE); db.collection("cat...
asked by 25.04.2018 / 20:23
3
answers

Add a custom listview in a fragment

I'm trying to use a custom listview in a fragment, I've already searched several pages and I've already searched in this forum, but I can not locate myself to adapt it to my own. My problem is that in code I can not get the custom adapter to...
asked by 18.10.2017 / 21:40
2
answers

Error trying to load google maps in a fragment? Android Studio:

Good morning, I'm doing the exercise of placing a map to my app, I already did an exercise that worked correctly for me using an activity, but now I'm doing it with Fragment in a navigation drawer and it shows me error in the line: Sho...
asked by 24.08.2017 / 16:26
2
answers

program my content on a 3.2 "mdpi screen and I realize that there is another 5.1" mdpi and its content looks small?

program the content of my app for a 3.2 "mdpi screen and it fits well, but when changing the view mode to a 5.1" mdpi it does not fit, help with this problem. 3.2 "mdpi 5.1 "mdpi     
asked by 27.01.2017 / 05:36