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 8801581
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T00:52:20+00:00 2026-06-14T00:52:20+00:00

I have created one scroll view with two list Fragments here is the code:

  • 0

I have created one scroll view with two list Fragments here is the code:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:background="@drawable/blue_shade_top_gainers_and_loosers"
    android:orientation="vertical" >

    <LinearLayout
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:paddingBottom="1dip"
        android:paddingLeft="1dip"
        android:paddingRight="1dip"
        android:paddingTop="2dip" >

        <fragment
            android:id="@+id/header_fragment"
            android:name="com.lk.ignitionit.cse.util.HeaderFragmentActivity"
            android:layout_width="match_parent"
            android:layout_height="wrap_content" />
    </LinearLayout>

    <ScrollView
        xmlns:android="http://schemas.android.com/apk/res/android"
        android:id="@+id/ScrollView13"
        android:layout_width="fill_parent"
        android:layout_height="match_parent" >

        <RelativeLayout
            android:id="@+id/rl_top"
            android:layout_width="fill_parent"
            android:layout_height="fill_parent"
            android:layout_marginBottom="1dip"
            android:layout_marginLeft="1dip"
            android:layout_marginRight="1dip"
            android:layout_marginTop="1dip"
             >

            <LinearLayout
                android:id="@+id/headg"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:scrollbars="vertical" >

                <include layout="@layout/top_gainer_header" />
            </LinearLayout>

            <fragment
                android:id="@+id/gain"
                android:name="com.lk.ignitionit.cse.application.TopGainersFragmentActivity"
                android:layout_width="match_parent"
                **android:layout_height="wrap_content"**
                android:layout_below="@+id/headg" />

            <LinearLayout
                android:id="@+id/headl"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_below="@+id/gain" >

                <include layout="@layout/top_loosers_header" />
            </LinearLayout>

            <fragment
                android:name="com.lk.ignitionit.cse.application.TopLoosersFragmantActivity"
                android:layout_width="match_parent"
                **android:layout_height="wrap_content"**
                android:layout_below="@+id/headl" />
        </RelativeLayout>
    </ScrollView>

</LinearLayout>

but the out put is not show the entire list

then i change the fragment layout height into 240dip instead of “wrap_content” now it’s enough to show entire list.
but the thing is, those data is dynamic and each list fragment have 10 list items.so i can’t predict the the fragment height. if the names are long, this height is not enough.

so i need to set fragment height as wrap_content and scroll able. how can i do this?

  • 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-14T00:52:21+00:00Added an answer on June 14, 2026 at 12:52 am

    There are several questions already on SO for this. There seems to be no perfect answer, but there are several pointers. Please do a search for them. One example:

    Scrolling with multiple listviews for android

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

Sidebar

Related Questions

I have created one UIImageView Here's code capView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:kARROW_CAP_NAME]]; capView.frame
I have created one scroll view and on the scroll view, i am adding
I have created following layout.which has two relative layouts and one scrollview ,following code
i have created one login and register view in that view after login user
I have created one custom view that contains the horizontalscrollview. Now when i changes
I have created one custom view that contains the horizontalscrollview. Now when i changes
In my application I have created 20 buttons with in a scroll view, now
Context: I have a TableLayout (created using XML), which has one TableRow, which has
I have created two buttons with pagescrolling. Now by clicking on one button the
I have a two column TableLayout as the only child of a scroll view.

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.