Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8170883
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T21:16:57+00:00 2026-06-06T21:16:57+00:00

i created a MonoDroid application where i have a ListView populated with a custom

  • 0

i created a MonoDroid application where i have a ListView populated with a custom row layout.

The custom row layout has 3 textview: lblA, lblB, lblC and an invisible imageview: img

So far so good, the listview populate itself correctly and all is working and displayed as expected.

However, i am currently facing a problem on item selection where i want the invisible imageview to become visible when an item is selected and invisible when selected again. The problem is that if i select an item and continue scrolling, the row seem to repeat itself and the visible imageview infinitly!

This is a custom visual selection i am trying to implement but it is not working as i was expecting.

Here is the code on an item selection:

private void listView_ItemClick(object sender, AdapterView.ItemClickEventArgs e){
    ListView lv = (sender as ListView);
    View row = lv.GetChildAt(e.Position);
    var item = row.FindViewById(Resource.Id.img);

    item.Visibility = (item.Visibility == ViewStates.Invisible) ? ViewStates.Visible :
                                                                      ViewStates.Invisible;
}

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T21:16:58+00:00Added an answer on June 6, 2026 at 9:16 pm

    I figured it out, i was thinking too hard actually.

    In my data List i added a ‘Selected’ boolean then modified my Adapter to toggle visibility based on this boolean.

    The boolean as its value affected on item click by accessing the array directly with my_list[e.Position].

    To change the visual effect of the moment i just access the view from e.View.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have begun evaluating MonoDroid. (I've built many apps using Android+Eclipse) I created new-from-template
Created a simple navigation controller based application. Application delegate class has Outlets for window
I installed Monodroid, created a new project and hit build (with Sharpdevelop) and then
I created a JButton which has an image set as an icon representing the
My monodroid application builds and runs fine, but breakpoints are not being hit. This
Created application is working toooo slow, looks like there are a lot of memory
created a singleview application with storyboard. Added three viewcontrollers apart from the one view
Created a custom validation attribute and I would like to get it to work
created a collection in MongoDB consisting of 11446615 documents. Each document has the following
Created a stored procedure in SQL 9 (2005) and have since upgraded to SQL

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.