Instantiates a layout XML file into its corresponding View objects
Questions tagged [android-inflate]
651 questions
0
votes
0 answers
Inflatable on alarm trouble
I'm trying to get an inflated layout to appear upon an alarm being received. So far the parent View is appearing but the inflated layout is not? can you tell me where I've gone wrong?, I am setting it up exactly like my timepicker inflatable but…

ToeKnee
- 47
- 1
- 10
0
votes
2 answers
Binary XML file line #..: Error inflating class fragment
I do not understand why I get this error only (for now) on aG alaxy Tab2 (Android 4.1.2 original).
On the Galaxy S3 (same version of Android) and PC simulation do not receive the error.
This is my code:
activity_dialogscore.xml (where I will put the…

user2263764
- 341
- 5
- 21
0
votes
1 answer
ViewGroup in event listener
I am trying to include a new layout on an event. For that I am using LayoutInflater in That event listener. But the problem is, LayoutInflater.inflate() function expect its parameters to be (Int) ResourceId, ViewGroup. I am unable to figure out what…

Sourabh
- 1,757
- 6
- 21
- 43
0
votes
2 answers
Android: Inflate Exception
I am new to android and I am trying to inflate a common footer in many activities of my android app. This some buttons in the footer need to work same across the app. Here is my code:
BottomBar class:
package com.traderscockpit;
import…

Sourabh
- 1,757
- 6
- 21
- 43
0
votes
2 answers
findViewById error when inflating spinner into view
I have a spinner that when selected should add a new spinner to the view. But when I try an inflate it I am getting an error on this line:
LinearLayout addSpinner…

Mike
- 6,751
- 23
- 75
- 132
0
votes
2 answers
Asynk Task calling in loop not giving the value return
I am try to create a application that will update the weather of multiple cities .Each row will have diffrent temp so i have use a AsynkTask. But i am not able to update the UI after getting the response from the API.
My Main Activity
public class…
user2568702
0
votes
1 answer
Styling Android Views from existing XML using an Inflator
How should I write my XML file, where should I put it and how should I reference them in the activity?
This is what I got:
myView = getLayoutInflater().inflate(R.???someplace???.???somename???, null);
What should be set instead of someplace and…

Victor Ferreira
- 6,151
- 13
- 64
- 120
0
votes
1 answer
How to solve : Binary XML file line #8: Error inflating class
My app consist on moving a picture when the user speaks. I have done this, but I have a problem while I try to set a image as background for my app. I am trying to do this using the xml file but I get the Error inflating class. Can anyone help me,…

user2804038
- 1,093
- 3
- 15
- 17
0
votes
4 answers
Styling Views created programmatically on Android
So guys I was reading that it's simply not possible to set the style of a view via Java. There is no such method myView.setStyle("styleName") yet.
Then when you create your layout elements by code, such as textvews, and imageviews or linearlayouts…

Victor Ferreira
- 6,151
- 13
- 64
- 120
0
votes
2 answers
Infalting the Layout showing not proper result
I am inflating a layout in a Linear Layout.But at run time it is not showing up the proper layout .data is getting mixed up with each other.No proper spacing between the data.
this is how it is looking up
This is my Activity Code
void…

Pooja Dubey
- 683
- 2
- 14
- 34
0
votes
5 answers
Get value of textview after Inflating in Android
I am inflating the passenger_details_layout in main_passenger_details_layout.At run time i am setting the values in TextView . I am setting up pax_id that is invisible for every row that i am inflating in it.So on click of passenger_details_layout…

Pooja Dubey
- 683
- 2
- 14
- 34
0
votes
2 answers
how to set a text of a textview from another activity
I am inflating a layout in the viewpager of the current activity but I need to set the textview text of this layout so that I can inflate it and it displays the new text I am doing :
LayoutInflater inflater = (LayoutInflater)…

User
- 509
- 2
- 8
- 23
0
votes
2 answers
Inflating custom view in android
I have created a custom view that show an arc compeleting into a circle. My objective is to show the view in my xml. I am trying to inflate my custom view class in my xml but it is giving me error. My objective is to show it in my mainactivity in a…

Vyshakh
- 632
- 1
- 11
- 29
0
votes
2 answers
How to position a inflated layout at the center of parent layout
I am inflating a layout(imageviewlayout) in Main layout.I am getting the child view at t he bottom of parent view.How can I align the child view at the center of Mainlayout.I have read that it can be done using Layoutparams .can you please tell how…

ss45
- 47
- 1
- 9
0
votes
1 answer
Blank the layout containing a Layout in Android On click
On create i am creating my layout problematically.After that on click on button i want to remove the previous layout content How could i do that i tried that removeView.But it didn't worked for me .Here is my code
void setDate(){
…

Developer
- 6,292
- 19
- 55
- 115