Instantiates a layout XML file into its corresponding View objects
Questions tagged [android-inflate]
651 questions
1
vote
0 answers
View on child layout is displayed underneath the view on parent layout
I'm going to create a remote control with a dynamic appearance. So, I want to add all buttons programmatically. Each button has background, icon, and ?selectableItemBackgroundBorderless drawables. According to this guide I've used two layouts to get…

h.nodehi
- 1,036
- 1
- 17
- 32
1
vote
1 answer
Android: inflate layout into fragment but onCreate don't start
I'm trying to use Fragments in android.
So in the method "getItem()" into the class "TabAdapter", I have:
public Fragment getItem(int position) {
switch (position) {
case 0:
Browse tab1 = new Browse();
…

Re De Pasquale
- 90
- 9
1
vote
2 answers
Error :Binary XML file line : Inflating class fragment
I have an activity MainActivity in which I have and fragment signup_fragment I want to call fragment from an activity but it gives an exception of Binary XML file line #23: Binary XML file line #23: Error inflating class fragment
and Caused by:…

SFAH
- 624
- 15
- 35
1
vote
3 answers
Error inflating class ImageButton Stops app from starting
My app fails to start because of Error inflating class ImageButton, Because of this the phone says "app has stopped" Etc.
I am using firebase test lab to debug the problem
the Errors occur on samsung devices specifically A20, s7 Edge , s7(tested…

Ruben Meiring
- 333
- 2
- 21
1
vote
2 answers
android.view.InflateException:Binary XML file line #17: Error inflating class fragment
i have checked all similar questions(This and others ) but still couldn't figure out the cause of the error, it keeps shutting down at some point during run time...
CategoryDetailFragment.java
/**
* A simple {@link Fragment} subclass.
*/
public…

X-Black...
- 1,376
- 2
- 20
- 28
1
vote
1 answer
Fragment is not showing up in suggestion when I try to inflate
I am trying to inflate one of my fragments. However, the fragment does not show up in the autosuggest. So I manually entered the name of the fragment. By doing that the fragment name was showing in red text color and also red squiggly lines showing…

Phil
- 97
- 8
1
vote
2 answers
Android 4.1 Crashing - XML (vector image)
I'm getting crashes trying to run my code in older android versions, but it works great on newer ones.
This is the log I get.
09-19 08:10:46.741 6803-6803/? I/art: Not late-enabling -Xcheck:jni (already on)
09-19 08:10:46.792…

Ricardo Rodrigues
- 366
- 3
- 19
1
vote
1 answer
android.view.InflateException: Binary XML file line #0: Error inflating class !
This is the method that can display the errors.
The error :
Caused by:
android.view.InflateException: Binary XML file line #0: Error inflating class
Caused by:…

Noder
- 313
- 3
- 15
1
vote
1 answer
Create View By "inflate" extends RelativeLayout,But was blank when using
I Dim a view by inflate the layout, Code like this:
public class MenuItemView extends RelativeLayout {
private Context context;
TextView tv_title;
String title = "";
TextView tv_content;
String content = "";
TextView tv_guid;
String guid =…

YunxiuWang
- 101
- 1
- 2
1
vote
1 answer
android.view.InflateException on specific device
First i did looked at other post and tried to find out answer but none of them helped me. So i thought of putting my question..During developer console crash review i noticed my app crashing on specific 2 device, the other device with same OS it…

Akshay
- 657
- 2
- 19
- 38
1
vote
1 answer
Found Weird layout InflateException
I have found a weird exception which is android.view.InflateException: Binary XML file line #0: Binary XML file line #0: Error inflating class .
And this exception occur only in api 21 and below that in my adapter class on rootView where I…

Anshul Singh
- 45
- 5
1
vote
1 answer
Layout Inflate Error Fragment
MainActivity:
public class MainActivity extends AppCompatActivity
implements NavigationView.OnNavigationItemSelectedListener {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
…

Ajay Mishra
- 13
- 6
1
vote
1 answer
Change background color of child views
I have a parent view and a child view. The child views are inflated programmatically. The child view has a TextView with some background. The TextView has a onclick event on it. What I want is when the user clicks the first TextView its background…

3iL
- 2,146
- 2
- 23
- 47
1
vote
4 answers
Android - Error when inflating custom View in XML
I have a custom view but I'm unable to use it because something related to namespaces that causing an Exception:
E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.pc.easycalc, PID: 30694
…

boctulus
- 404
- 9
- 15
1
vote
2 answers
Inflating Nested Layout with RadioButton to a Container
I have created a layout that will be inflated to a container this layout contain radiobutton
Problem: The layout inflated but all the radio button get checked, is this wrong?.
Layout containing radio button to be inflated in the…

TABZ
- 125
- 12