listview

How can I update one view at a time in an ArrayAdapter?

I want to be able to access my ArrayAdapter's view: public View getView(int position, View convertView, ViewGroup parent) I'm not sure how I can access this: View myView = myArrayAdapter.getView(myPosition, myView, ?); I am not sure how I can get a ViewGroup parent? ...

Android Customized ListView

I am having a Srollview in for my entire layout.In that i added a listview.when i scrolling the page ,tha page scrolls normally,but when it reaches listview listview only scrolls how to overcome this problem. Please any one can suggest the answer. I am looking that when i scroll the listview the whole page gets scrolled. ...

Lazy List with images and progress display

I have found this example http://stackoverflow.com/questions/541966/android-how-do-i-do-a-lazy-load-of-images-in-listview/3068012#3068012 from Fedor which is absolutely great for what I need. I have a question. if beside the Clear Cache button there would be a TextView how could I put in there how many images from total images had dow...

Focus an item in ListView with VirtualMode enabled

Hi I have a ListView in VirtualMode. I need a way to set focus to specific item. The FocusedItem is not good for the VirtualMode, I need a way to set FocusedIndex or something like that, but didn't see any property like that. Thanks. ...

How can I make my ArrayAdapter follow the ViewHolder pattern?

Here is my ArrayAdapter. I would like to make this more efficient by following the ViewHolder pattern: http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/view/List14.html but am not sure how to accomplish this. UPDATE: ViewHolder Pattern private class QuoteAdapter extends ArrayAdapter<Quote> { ...

Android: compass + distance in a listview.

Hello, I guess you have all tried "Google Places" in Maps. This is a list of POI close to you. I really would like to do the same feature in my application with a list of GPS coordinates, but that seem really complicated. Making the listview with the distance and the little arrow is very easy, but I cannot understand how to update thi...

How to differentiate between a fling and a touch?

I have a ListView inside of a ViewFlipper which I am flipping when the user swipes across the screen. Clicking on a ListView will open the browser. Sometimes when I am swiping, it gets detected as a touch on the ListView and will open the browser. This can be annoying. How can I prevent this from happening? class MyGestureDetector exten...

Custom ListView to show EmptyDataTemplate and InsertItemTemplate at the same time

It is known that the ListView control can't display both an EmptyDataTemplate and a InsertItemTemplate at the same time. For my design style I need to be able to show both. I want to be able to show that no data exist and at the same time show a form to add new data. I've already implemented various solutions, such as putting a PlaceHo...

How do i increase the view size of my list view?

here is the xml code i used but no use even if try increasing the minheight.... please help <?xml version="1.0" encoding="utf-8"?> <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <!-- Here you put the rest of your curr...

Lazy List with Images. How to cancel thread ?

I have found this example http://stackoverflow.com/questions/541966/android-how-do-i-do-a-lazy-load-of-images-in-listview/3068012#3068012 from Fedor which is absolutely great for what I need. I have a question. if beside the Clear Cache button there would be a button with Cancel. How could I in onClick cancel the image download thread...

How to obtain subviews from listview in android ?

Hello everyone, My program will show data based on selection from two spinners (month and year). Based on month and year, it will query DB and displays the content in listview. I created two spinners and populate with array string. Then I created two spinner views, two arrayadapters and set onItemSelected listeners and set adapter to t...

ListView selection problem - Caching prevents selection of many items

Hi. I have a problem with the way a ListView selects its items. I have a ListView bound to an ObservableCollection of items which have a 'Selected' property. I have bound the selection state like this: <ListView.ItemContainerStyle> <Style TargetType="{x:Type ListViewItem}"> <Setter Property="IsSelected" Value="{Binding P...

WPF ListView non integral scrolling

How do I turn off the integral scrolling in a WPF ListView? By default, scrolling a ListView jumps down so I must scroll a whole item at a time. I would like to scroll half way, quarter way, etc. ...

Passing a value along from a Button in a WPF ListView

I have a collection that I am displaying in a WPF Listview. I will have an edit button in each row and need to pass an ID to another control on the screen when that's clicked. I'm not going to be editing in place so I'm not using the Gridview. How do I pass this ID to my other control? Currently my XAML looks like this. <ListView Na...

Section header in ListView not show correctly

This question is the same as my another question http://stackoverflow.com/questions/3648840/listview-with-section-header-problem When scrolling the ListView, some header text will appear, below are the related code for easier understanding: records.setViewBinder(new SimpleCursorAdapter.ViewBinder() { public boolean setViewValue(Vie...

Can't get ListView items to show up in android program!

I have a listview that I would like to use to display a list of strings. The problem is the items don't show up. Can anyone tell me what I am doing wrong? Here's my code: import java.io.File; import java.io.FileFilter; import java.util.ArrayList; import android.app.Activity; import android.os.Bundle; import android.os.Environment; imp...

Problems with ListViews

Hi, I'm having a several issues with ListViews. The first problem is the layout that I use for every row of the listview. When I click in a row I've programmed that it expands with some other views. All works fine, but when I try to click again for shrink it, it seems that it's no focusable and doesn't highlight and, of course, it doesn...

How to correctly handle Android EditText input inside a ListView?

In my application I have an activity to add/remove/edit records inside a SortedMap. The activity is implemented as an extension of ListActivity. I have implemented custom ArrayAdapter for the collection items. Every ListView item (which corresponds to an underlying record) consists of TextViews, EditTexts, and a Button to delete the rec...

Why won't expandablelistview work with context menus?

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 cust...

Adding animation to a ListView in order to expand/collapse content

I have a list view which uses a custom adapter in order to show my custom content. Its layout is the following. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"> <LinearLayout android:...