listview

How can I line up WPF items in a Horizontal WrapPanel so they line up based on an arbitrary vertical point in each item?

I'm trying to create a View in WPF and having a hard time figuring out how to set it up. Here's what I'm trying to build: My ViewModel exposes an IEnumerable property called Items Each item is an event on a timeline, and each one implements ITimelineItem The ViewModel for each item has it's own DataTemplate to to display it I want to ...

ListView Control and Details

Hi All, I'm a bit confused by a few tutorials that I read about the ListView. I have a ListView control and on the left hand side should be a name, and to the right of that name should be like another column with some more text in it. For example: ListView: jason blah blah blah item2 more blahs item3 jupiter item4 ...

Safe, standard way to load images in ListView on a different thread?

Before making this question, I have searched and read these ones: http://stackoverflow.com/questions/541966/android-how-do-i-do-a-lazy-load-of-images-in-listview http://stackoverflow.com/questions/1409623/android-issue-with-lazy-loading-images-into-a-listview My problem is I have a ListView, where: Each row contains an ImageView, whos...

onListItemClick with Mulitple Value/Retrieving Value

**Hello, I am trying to retrieve the 2nd value from a Arraylist/ArrayAdapter that I have populated. I am new to Array so please correct me if I am wrong Q1. I created the Array Favorite. What I think what I created is an Array with two set of value call Detail | Value. example Detail="Yasmin",Value="8". Is this correct? Q2. I have a...

Android ListView scrolling to top

Hi, I have a ListView with custom rows. When any of these rows is clicked, the ListView's data is regenerated. I'd like the list to scroll back to the top when this happens. I initially tried using setSelection(0) in each row's OnClickListener to achieve this but was unsuccessful (I believe because the ListView loses its scroll posit...

Android: Context menu doesn't show up for ListView with members defined by LinearLayout?

I've got a ListActivity and ListView and I've bound some data to it. The data shows up fine, and I've also registered a context menu for the view. When I display the list items as just a simple TextView, it works fine: <TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/nametext" android:la...

Get SubItem value when double-clicking on Item in ListView

Hi All I have a listview with 2 columns, and when the I double click on an item, i need to display the value of its corresponding sub item in a TextBox control. How can I do this? I searched Google, but it didn't return anything helpful, probably because I'm not exactly sure what to search for. Thank you ...

WPF ListView GridView DisplayMemberBinding Center alignin content

I'm trying to center align data in a ListView/Gridview where I use DisplayMemberBinding. This is (partially) how my gridview looks: <ListView> <ListView.View> <GridView> <GridView.Columns> <GridViewColumn DisplayMemberBinding="{Binding Path=Timi}" Width="Auto"> <GridViewColumnHe...

ListView into ControlTemplate, scroll to last element

I have a ListView into a controlTemplate, such that it's property Name is not accessible in code behind. My listView is upgraded with ObservableCollection in real time with a large amount of data. How can i make ListView scroll to last element automatically, such that last element added to be seen first? Please Help! ...

Listview...how to conditionally replace a value with a string

Hi, my ANDROID app presents a listview, from a database cursor and XML, that needs to replace the values in a column with various words based on the integer value contained in the cursor. For example, if the value is -1, replace it with the word "Invalid", but if the value is >= 0 then just display the value. I was under the impression...

Android: how to set click events on ListView?

Hey there, I'm looking to be able to open up a new view or activity when I click on an item in my ListView. Currently I have a list of restaurants, and when i click on a particular restaurant I want it to open up another screen that will show its address, google map etc. What I need help with is knowing how to set click events on the ...

Listview: So you think you know itemDataBound?

In my webpage i use the following in order filling the listview control <asp:ListView ID="ListView1" runat="server"> <layouttemplate> <asp:PlaceHolder id="itemPlaceholder" runat="server" /></layouttemplate> <ItemTemplate> <tr> <td><asp:Label ID="Label1" runat="server" Text = '<%# DataBinder.Eval(Container.DataItem, "Ans1") %...

How can you manually reorder a ListView in Android?

I have a ListView in Android that needs to have the ability to be manually reordered. An example would be within Android's Music Player application, when you can change the order of tracks in a playlist. I know how to programmatically change the order of a ListView, but not how to do it in regards to a touch and slide approach that can b...

Get text from listview onclick (Android)

I am creating lists in my android app and would like to capture the text of the list item that is clicked but I want to do it in a seperate function so I only have to write the code once. And I want to be able to compare the string to another sting. What is the best way to do this? ...

Changing Orientation, losing all my list items

While I tested my application on an Android Device turning my Android phone from landscape to portrait, results in all the list items in my list view are disappearing. Why? How to manage? ...

Cell (SubItem) editing in ListView using VBA

Hi, How to implement cell editing for ListView SubItems in VBA? I would like to use ListView as an editable Grid on a VBA UserForm. ...

Android: onListItemClick not opening up the .xml file

Hi, public void onListItemClick(ListView l, View v, int position, long id) { if(position == 0){ setContentView(R.layout.cuisine); } } I have an array of Strings and i'm using the above method to try and open up a new xml file called 'cuisine' when it is clicked. but it keeps failing! Have I done this right, or what a...

How to display List<> using ListView?

When I use ListView to display a array of my object, I can use the following code: MyObject[] myObject; ... ArrayAdapter<MyObject> itemList = new ArrayAdapter<MyObject>(this, R.layout.list, myObject); setListAdapter(itemList); In case that the input is a list: List<MyObject> myobject; How can I assign it to ListAdapter? Please...

Android: disabling highlight on listView click

I want to disable the orange highlight that occurs when touching a listView row. So far in my xml I have tried the following: android:focusable="false" android:focusableInTouchMode="false" android:clickable="false" More information: I want there to be zero difference when a user touches the screen on this listView object. ...

Android List View Drag and Drop sort

I have a list of records in a listview that I want the user to be able to re-sort using a drag and drop method. I have seen this implemented in other apps, but I have not found a tutorial for it. It must be something that others need as well. Can anyone point me to some code for doing this? ...