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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T00:42:12+00:00 2026-06-09T00:42:12+00:00

I wanna do such a layout in android, i can’t figure it out. one

  • 0

I wanna do such a layout in android, i can’t figure it out.

one button on top, one button at bottom, and a listview take the rest center area, how to make the listview take the rest area? is this possible if parent container is vertical LinearLayout?

thanks

  • 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-09T00:42:13+00:00Added an answer on June 9, 2026 at 12:42 am

    What i have done in my project is

    <?xml version="1.0" encoding="utf-8"?>
    <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:orientation="vertical" >
    
        <Button
            android:id="@+id/task_title"
            android:layout_width="fill_parent"
            android:layout_height="wrap_content"
            android:layout_alignParentTop="true"
            android:text="@string/tasks" />
    
        <ListView
            android:id="@id/android:list"
            android:layout_width="fill_parent"
            android:layout_height="wrap_content"
            android:layout_below="@id/task_title" 
            android:layout_above="@+id/add_button">
            <!-- Preview: listitem=@layout/task_list_item -->
        </ListView>
    
        <TextView
            android:id="@id/android:empty"
            android:text="@string/no_tasks"
            android:layout_width="fill_parent"
            android:layout_height="wrap_content"
            android:gravity="center_vertical|center_horizontal"
            android:layout_below="@id/task_title" 
            android:layout_above="@id/add_button"/>
    
    
        <Button
            android:id="@id/add_button"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentBottom="true"
            android:text="@string/plus_sign" />
    
        <Button
            android:id="@+id/remove_button"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentBottom="true"
            android:layout_toRightOf="@id/add_button"
            android:text="@string/remove_task" />
    
    </RelativeLayout>
    

    With relative layout you can simply do it, the key layout properties are android:layout_alignParentBottom="true" , android:layout_alignParentTop="true"

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

Sidebar

Related Questions

i wanna creat a website for downloading some files (pdf,word,xls, such as these files),
I have a condition such as 'a==1' stored in property $(c) and I wanna
I wanna use the Gdata Apis within my Android Application. Being more specific I
Well, I have a problem (ok, no real problem, but I wanna try out
I wanna make a init method which can understand these contstrutors. candy(name=foo, type=bar) or
I wanna customize the toggle state of the toggle button in wpf. I want
I wanna build my own chat client using xmpp on android to chat with
This question regards how one can effectively create and persist event domain objects on
**FACTS** player(milan,[seedorf,zambrotta,gattuso]). player(inter,[seedorf,ronaldo,zambrotta]). player(realmadrid,[seedorf,zidane,ronaldo]). i wanna create a predicate such that : find (TEAM,
I wanna write a function like this function (str, find){} such that when I

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.