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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T18:17:00+00:00 2026-06-06T18:17:00+00:00

I need a GridView with rows with different height. Only for rows, not for

  • 0

I need a GridView with rows with different height. Only for rows, not for items inside a row. In a row the items have the same height.

I already tried to do that with Android’s GridView but got strange things. The grid distorts when scrolling up and down and at some point, when scrolling up, it dissapears. If I put all rows with the same height, it works, but as soon as they are a bit different, the problem appears.

So it seems I have to make a custom view. It has to have very good performance and low memory usage. Would be enough to extend, for example, Relative Layout, and put all my items with certain top and left margin? Or do extend View and draw directly to the canvas? Or a Scroller?

Embedded question: Will this, (maybe it depends if I extends some Layout or directly View), manage to load only the things which appear on the screen (the list is very long and I don’t want all the objects in memory at once) or do I have to implement this myself?

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-06T18:17:03+00:00Added an answer on June 6, 2026 at 6:17 pm

    I don’t think you can do it and get “good performance”. What makes Android efficient is it’s recycling of views. With different row heights from row to row, I don’t know how it could recycle views in any sort of efficient manner (or at all).

    I guess it depends on if the row height differences are known/knowable and how many there would be and if they would be in any pattern that could be predicted so you could set a custom adapter to handle the view recycling.

    If you can determine the above, then extending an adapter and handling the view recycling yourself is probably the answer.

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

Sidebar

Related Questions

Need some help with DataFormatString in GridView. I have a Double value that needs
I have a GridView that I need to dynamically add TemplateField elements to. My
I have a Gridview that has a timestamp as one of the rows. When
I have a GridView which displays in excess of 30000 rows, and users need
I have a GridView with Cell 0 containing the ID that I need to
I have a Gridview in which no rows populated initially. means i am not
I have a gridview that shows (50)rows of data per page. I have the
I have a custom GridView that will show 6 rows of data as a
i have a gridview that creates a new row with a new gridview in
I have a gridview with four template fields that I need to be able

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.