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

  • SEARCH
  • Home
  • 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 7009221
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T21:50:05+00:00 2026-05-27T21:50:05+00:00

I have a listview in my application. I have 5 columns in my listview

  • 0

I have a listview in my application. I have 5 columns in my listview and items are displayed dynamically. The problem is when I scroll my list the total list selected and the background of the listpage will be changed as black color.

Here my code is:

<TableLayout  
    xmlns:android="http://schemas.android.com/apk/res/android"  
    android:id="@+id/tableLayout1"  
    android:layout_width="match_parent"  
    android:layout_height="match_parent"  
    android:shrinkColumns="*"  
    android:stretchColumns="*"
     android:background="@drawable/bg">




     <TableRow  
        android:id="@+id/tableRow1"  
        android:layout_height="wrap_content"  
        android:layout_width="match_parent">    


          <TextView 
              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/t1" 
              android:text="Tname"               
                 android:typeface="serif"
                  android:padding="3dip" 
             android:textColor="#9400D3">             

                       </TextView>
<TextView  
              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/t2" 
              android:text="From"                            
                   android:textColor="#9400D3"               
                  android:typeface="serif"   
                           >
              </TextView>
<TextView 

              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/t3" 
              android:text="Arrival"            
                android:textColor="#9400D3"
                  android:typeface="serif"
             >
              </TextView>
<TextView 

              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/t4" 
              android:text="To" 
                android:textColor="#9400D3"             
            android:typeface="serif">
              </TextView>

<TextView
        android:id="@+id/t5"
         android:layout_width="wrap_content"
    android:layout_height="wrap_content"   
    android:text="Departure"
     android:textColor="#9400D3"  
            android:typeface="serif"  

     >
</TextView>
  </TableRow> 


    <ListView
        android:id="@id/android:list"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentLeft="true"
        android:layout_marginTop="10px"
        android:dividerHeight="1px"

        android:paddingLeft="0px" 
        android:focusable="false">

        </ListView>

</TableLayout>

my items listpage

<TableLayout  
   xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/tableLayout1"  
    android:layout_width="match_parent"  
    android:layout_height="match_parent"  
    android:shrinkColumns="*"  
    android:stretchColumns="*"
    android:focusableInTouchMode="false"  >  
     <TableRow  
        android:id="@+id/tableRow1"  
        android:layout_height="match_parent"  
        android:layout_width="match_parent"

       >    


<TextView 
              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/train" 
              android:text="train" 

              android:textColor="#FF0000" 
                 android:typeface="serif"
                  android:padding="3dip"               
              >
              </TextView>
<TextView  
              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/from" 
              android:text="From" 

              android:textColor="#292421"
                 android:typeface="serif"

              >
              </TextView>
<TextView 

              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/arr" 
              android:text="arr"             

                android:textColor="#000080"
                   android:typeface="serif"

             >
              </TextView>
 <TextView          
              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/to" 
              android:text="to"              
                 android:textColor="#292421"
                 android:typeface="serif"

              >
              </TextView> 
<TextView 

              android:layout_width="wrap_content" 
              android:layout_height="wrap_content" 
              android:id="@+id/dep" 
              android:text="Location" 

              android:textColor="#000080"
                 android:typeface="serif"
              ></TextView>
</TableRow>
</TableLayout>

Please, tell me where I have done wrong..

  • 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-05-27T21:50:06+00:00Added an answer on May 27, 2026 at 9:50 pm

    set cacheColorHint="#00000000" in Listview property

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

Sidebar

Related Questions

I have a ListView item in my application. The scroll position does not get
In my application, I have a listview whose list item consists of a TextView
I have an Android application with a ListView in it, the ListView will setup
I have listview control.There is an option to remove selected items.After the user removes
I have a list view with multi columns... Want to change the background color
In my application i have a listView. each item of the list view contains
In a WPF application I have a ListView: <ListView Name=ItemSelList ItemsSource={Binding ItemColl} SelectionChanged=ItemSelList_SelectionChanged> <ListView.View>
In my application, I have list view. Selecting another item in it, triggers an
I have a C# WinForm application where I am using a ListView to show
I have a problem displaying the results of an sql query into a ListView

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.