Android : Switch From A TableLayout To An ExpandableListView?
May 26, 2010
Is it possible to switch from a TableLayout to an ExpandableListView? How? I tried using ViewFlipper but the fact that ExpandableListView doesn't use XML threw a wrench in it.
View 1 Replies
Oct 30, 2010
I have a two column TableLayout as the only child of a scroll view. The first column contains TextViews ('labels') and the second column contains EditText/Spinner/DateWidget etc ('values').
Even though I have have specified android:layout_width="fill_parent" for TableLayout, TableRow & all widgets (in 'values' column).
The screen looks perfect when the activity is created. However, when one types a really long value in the EditText, the 'values' column goes beyond the visible screen area.
View 3 Replies
View Related
Oct 27, 2010
I need to implement an xml parser and the parsed result into an expandablelistview.
View 1 Replies
View Related
Jul 29, 2009
I have an expandable list view with a static array for the group data and an SQLite database for the child data. It is implemented with the BaseExpandableListAdapter and works great, except, when I edit the database to delete or add children to the list I do not see the changes onscreen. It looks like I can use the registerDataSetObserver method to notify the adapter and expandable list of a data change. What I have to do in the callback to make Android redraw the list after data changes is what I need to know. Can I do it? Documentation on this part of the SDK is a bit sparse and expandable list view example code is not a good match. Can anyone offer advice on how to use a DataSetObserver? It feels like I have to switch over to a Cursor type adapter.
View 2 Replies
View Related
Dec 15, 2009
This is my ExpandableListView
CODE:..............
When I execute this in emulator, green(childDivider color) is all over the place.
It seems if childDivider is ColorDrawable, it has no bound.
View 2 Replies
View Related
Mar 18, 2010
I have an ExpandableListView with several groups and each group contains several children. I want to make this list searchable, just like a regular list view. I have a SimpleCursorTreeAdapter (mAdapter) for this expandlable list.
I tried to use the built in list filter using:
CODE:.......
The above code does not work for filtering.
How can I implement the search/filter functionality?
View 2 Replies
View Related
Sep 17, 2010
Is it possible to animate the expanding and collapsing of the groups in a ExpandableListView.
View 3 Replies
View Related
Jun 17, 2009
I need a solution how to get the OnChildClick working for my ExpanableListActivity.
when starting of this project the Listener was working, but now i get nothing out of it?
i tried setting the listener through: "getExpandableListView().setOnChildClickListener(this);" at several point, but it isn't responding.
Here's the source code:
CODE:............
View 3 Replies
View Related
Jul 18, 2010
I want to inflate a childView of ExpandableChildView component.
Code:.............
Where linearOpt is a vector that contains a lot of LinearLayout objects that I have instantiated.
CODE:..
This is R.layout.itemrow xml:
But I received this error:
CODE:.................
View 1 Replies
View Related
Oct 20, 2010
I want to refresh my expandablelistview, but it seems there is no way to use notifyDataSetChanged()? how can i refresh my expandablelistview?
View 2 Replies
View Related
May 14, 2010
I'm trying to add a context menu to my ExpandableListView. I've implemented onCreateContextMenu() and onContextItemSelected() but if I hold my finger on a menu item context menu doesn't appear. What's my mistake?
View 1 Replies
View Related
Aug 12, 2010
I have an ExpandableListView bound to a SQLite database. To simplify things, lets assume the database contains two columns: title and body. In the ExpandableListView, there is a group for each title, and a childfor each corresponding body.
Now to make things more interesting, some of the rows in the SQLite database do not have a body (that is... they only have a title). As you can see, if there is no body, then there is no reason to expand the group... because the child will be empty (i.e. String body == "").
I'm searching for a way to catch a situation like this, and skip the group's expansion. I don't want a blank child to be expanded. To put it in psuedo code, I want something like this:
CODE:...............
View 1 Replies
View Related
Apr 24, 2010
My problem is when I want to refresh data in ExpandableListView while being in that current activity. I create adapter and when I want to add new data to list I call again constructor of that adapter(it is my private variable) with all new data....and then I call onContentChanged() method to redraw my list.
But what happens is that I cant expand my list any more...like it is blocked or something and logcat isn't saying anything...
This is the code that i call after setting new data in arraylists and maps:
CODE:....................
View 1 Replies
View Related
Nov 2, 2010
I'm trying to create a ExpandableListView in one activity. I've looked in apis demos, and I've created ExpandableListView. The problem is, that I need to have this ExpandableListView in activity that is already created, and not in a new one.
I've used this code:
CODE:..............
View 3 Replies
View Related
Nov 5, 2010
Is it possible for the child of an ExpandableListView also be a parent?
For example, I need something like the following: ParentA ChildA ChildB ParentB ChildC GrandchildA? GrandchildB? ParentC
View 4 Replies
View Related
Dec 2, 2009
I'm using an ExpandableListView in one of my activity in a RelativeLayout
CODE:.............
And I'm using a custom expandableListAdaptaer which group view is:
CODE:............
(Found on examples of API_Demos, ExpandableList1)
A user of my application report me this photo http://binomed-android-project.googlecode.com/issues/attachment?aid=-... As you can see, the indicator of group items is over the text of group item despite the padding of 36...
And if I'm running emulator WVGA800 or an emulator with "abstracted LCD density" to 240 I have the same problem, but with my phone (HTC G1), I don't have any problem.
What is strange is that I try the application API_Demo with an emulator WVGA800 or an emulator with "abstracted LCD density" to 240 and I go to ExpandableList1 activity and all is alright !
I also try to copy the inner class available in ExpandableList1 for adapter and I launch it into my activity and I also have the problem see on photo
I am forced to manage density into my adapters in order to adjust the padding?
View 3 Replies
View Related
Sep 16, 2010
I'm trying to customize the parent(or header) for an expandablelist and I haven't found a solution yet. I want an imageview and two textviews in the parent. This is driving me insane atm.
View 2 Replies
View Related
May 12, 2010
Is it possible to make a multiple choice list with android:choiceMode="multipleChoice" or setChoiceMode(ListView.CHOICE_MODE_MULTIPLE) on an ExpandableListView? I am able to do this with CheckBoxes on a plain ListView, but it doesn't seem to be working with ExpandableListView. In the latter, clicking the list item (either parent or child) does not affect the checkbox as it does in the former.
I have noticed that it is possible to click exactly on the checkbox to make it toggle, but this is a very small target.
View 1 Replies
View Related
Jun 4, 2010
I need to get item's index(position) knowing its ID while using ExpandableListView. Is there any way to do this without making complete hash id->index and searching it?
View 1 Replies
View Related
Aug 11, 2010
The default behavior of ExpandableListView is to collapse a group when its header is clicked. Is it possible to prevent this from happening?
I've tried: Setting OnTouchListener on the list. This interferes with scrolling. Setting an OnGroupClickListener on the list (in onCreate()). This works for all clicks after the first.
Why might the OnGroupClickListener miss the first click?
View 2 Replies
View Related
Oct 5, 2010
I have a 2d array of strings. I would like to use a spinner to allow users to select values from the 2nd lvl of the array but I would like to display the selection options in a expandablelistview using the values of the 1st lvl of the array as category headers. Is this possible, how this should be implemented ?
View 1 Replies
View Related
Sep 3, 2010
Im trying to implement an activity that uses ExpandableListView and I have gotten so far but now I have found some strange behavior.
My activity is meant to record food intake as specified by the user. they have a choice of menus (breakfast, lunch and dinner - the outer group) which expand to show their contents.
when a user clicks on an inner menu item a dialog appears asking them for the qty. once they enter a qty and dismiss the dialog the text on the menu item changes to reflect the quantity of that item that has been consumed
The above image shows the list in a closed state.
Below is the list after I have opened the lunch menu and clicked on 'Potato Chips' and indicating a Quantity of 1. As you can see the 'Potato' itemtext has now been changed to reflect the Qty of 1.
The strange part happens now. if I click on 'Lunch' and close the list and then click on it again re-opening it, the 'Qty X 1' text has jumped to another item (Milk)
Each time I open and close the list it jumps back and forth between the two items. Also if I open up other items, such as breakfast, I find that they too have now gotten items with 'Qty X 1' even though I havent clicked them.
The bits of code that are relevant are as such:
The XML for a child element:
CODE:................
The code thats triggered on clicking a child element:
CODE:..................
The above code opens a dialog, accepts a value for quantity, appends the list element to reflect this, also saves to database and sets a textview with the selected item and quantity.
View 1 Replies
View Related
Feb 16, 2009
I think that there is possible bug in TableLayout SDK 1.0 rc2 when constructing table from code. It seams that the weight or height attribute is not respected when rendering the layout.
The XML view creates a table with row at the top and row at the bottom of the screen which is what supposed to happen, so I created this same table via code but the results are not what were expected. Maybe I am missing something but it seams OK, all LayoutParams are this same.
Sample Code ...
If anyone else can confirm this I will post this as a bug.
View 4 Replies
View Related
May 4, 2010
I have the following problem: I would like to change value of ExpandableListView's cell on click. How should I do that?
Here is what I'm using:
CODE:............
Application is in progress stage, so attrVal will contain several attributes ( which can be put or not depend on some logic), so I'm using this type of adapter and this way of filling cells' data.
fieldsInList - external variable of LinkedHashMap type.
I have a function which can change one of the member's of fieldsInList variable. How should I notify my expListAdapter or ExpanableListView to be refreshed?
View 2 Replies
View Related
Aug 28, 2010
I have subclassed ExpandableListActivity to create an activity that presents a simple tree view of the 'world at large' and allows the user to select one for further use by the app. I am having trouble setting focus programatically. One thing that baffles me is that I can use the D-pad to set focus on any of the child or group items in my ExpandableListView, but inside my onChildClick() callback, isFocusable() returns false. If I can set focus with the D-pad, how can isFocusable() return false?
My goal is to avoid having the user have to touch individual ExpandableListView entries to select them and to provide a couple of buttons to move the focus up and down inside the list. I want selection to be easy for folks with no D-pad or with a phone that only presents the D-pad when in landscape mode (e.g. Droid) .
Is there some way I can programatically inject D-pad key clicks into my app input event stream?
View 2 Replies
View Related
Nov 4, 2009
Is it possible to display the ExpandableListView indicator in right side?
View 2 Replies
View Related
Jan 27, 2010
I have an ExpandableListView contains a link, it does not expand when has a link, and i want the link is clickable.
CODE like this:
CODE:..............
And:
CODE:........................
View 1 Replies
View Related
Jul 14, 2010
I need to completely remove dividers from ExpandableListView. As for parent items it's a setDividerHeight method where I can pass a zero value. But there's no similar method for child divider. Is there any way to hide it?
View 1 Replies
View Related
May 3, 2010
I'm using "ExpandableListView" in my application to display some options that . I need a way to build automatically the information to show when a group is expanded as the information might be different each time the group is expanded.
View 1 Replies
View Related
Oct 3, 2010
My app used to use a standard ListView, and registerForContextMenu(getListView()) and everything worked just fine.
I needed to change my app to accommodate nested lists so I replaced the ListView with ExpandableListView. I changed the Activity to ExpandableListActivity. I also changed my adapter to a tree adapter and implemented a custom view class to populate the list with (based on a FrameLayout view).
Suddenly my context menus stopped working and I can't figure out why. I can't long click on any of my list items and I'm completely stuck on where to start looking.
View 1 Replies
View Related