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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:14:06+00:00 2026-05-17T19:14:06+00:00

i have content i need to display above my listview and below, so much

  • 0

i have content i need to display above my listview and below, so much that a scrollview would be great to use if you could use scrollviews and listviews together. Since thats not the best solution, i’ve been trying to do a couple of things to add footer content to my listview,

here the pic below shows what happens when i add a different type of row as the last row. I can’t get my content to fill the width of the row

alt text

I have a couple of buttons that need to go in the footer. I’m using a custom adapter that extends BaseAdapter.

I have also tried using the addFooterView but i’m confused on how to use the addFooterView method if you are implementing your own adapter. Anyone have any simple examples of how to implement addFooterView on a custom adapter

or

is there a way i can get the row at this position (as seen in the picture ) to display better, here is the code i’m using to create this footer row

        View v = getLayoutInflater().inflate(R.layout.item_listview_footer, null);
        LinearLayout ll = (LinearLayout) v.findViewById(R.id.ll);
        return ll;  // return ll as convertView in getView function

edit:

here is the xml for my footer layout

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_height="wrap_content" android:layout_width="fill_parent" android:background="@drawable/red" android:orientation="vertical" android:id="@+id/ll">
    <Button android:id="@+id/specialInsButton" style="@style/button" android:text="Add Special Instructions" android:layout_width="fill_parent"/>
    <Button android:id="@+id/addToBagButton" style="@style/button" android:text="Add To Bag"/>
    <EditText android:id="@+id/quantity" style="@style/standard" android:text="1"/>
</LinearLayout>

here is the xml for style/button

<style name="button">
        <item name="android:layout_height">wrap_content</item>
        <item name="android:layout_width">fill_parent</item>
        <item name="android:textSize">17px</item>
        <item name="android:textStyle">bold</item>
        <item name="android:typeface">sans</item>
        <item name="android:gravity">center</item>
        <item name="android:layout_gravity">center</item>

    </style>

standard style

 <style name="standard">
        <item name="android:layout_height">wrap_content</item>
        <item name="android:layout_width">wrap_content</item>
    </style>
  • 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-17T19:14:07+00:00Added an answer on May 17, 2026 at 7:14 pm

    You can use addFooterView with a custom adapter. Just be sure to make the addFooterView call before the call to listview.setAdapter().

    View v = getLayoutInflater().inflate(R.layout.item_listview_footer, null);
    listView.addFooterView(v);
    listView.setAdapter(adapter);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a div with some inner content that I need to have an
I have a scenario that, I am creating dynamic html content and I need
I need to echo entire content of included file. I have tried the below:
I have a container MovieClip that serves as a content area that I need
I have a content type that references multiple nodes, and I need a way
I have a string-array, that i need to display in a layout. The code
I need to develop a site on Drupal 7. I have some content types
We have the rails app, content served from the database. Now we need to
Hi i have Tab activity(Chapter,subject) and database. i need to show the chapter_table content
I have content management system application that uses a polymorphic tree table as the

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.