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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T00:48:17+00:00 2026-05-20T00:48:17+00:00

Seen a lot of tutorials with all different types of layout, but not clear

  • 0

Seen a lot of tutorials with all different types of layout, but not clear on how a layout could be dynamically applied based on the item.

Lets assume a list with items that derive from a common type like book, but a different subclass of book like paperback or audio book would get a completely different layout. So we would have one layout per class/type of object in the list. Evey item has some common properties but others have some additional properties.

So for example

Row 1 Description Text Clickable Button ItemType = A
Row 2 Description Text CheckBox ItemType = C
Row 3 Description Text Spinner ItemType = B
Row 4 Description Text Clickable Button ItemType = A
Row 5 Description Text Checkbox ItemType = C

So essentially the item type is determining the layout. ItemType A always have Clickable Item, ItemType C always CheckBox, ItemType B always a Spinner, and all layouts have a description text. I have not seen how the layout would be dynamically applied to list elements based on an element of the array of data. How could this be done or better yet is there a good example on this. 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-05-20T00:48:17+00:00Added an answer on May 20, 2026 at 12:48 am

    Seen a few of these questions lately. One solution is to override the getView method of the adapter and determine which layout to apply at runtime for each item in your list. It’s a fair amount of work, but it does what you want for the non-standard implementation that your asking for.

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

Sidebar

Related Questions

I've seen a lot of text based Assembly tutorials but finding it tough to
Background Job gets mentioned a lot but all the tutorials I've seen seem to
I'm new to ASP.NET, but I've seen a lot of tutorials and even have
Seen a lot for dropping tables using a wildcard but not a direct SQL
Some advice needed.... I've seen a lot of discussion about different approaches to performing
I have seen lot of threads about loading a PDF in Android Webview. But
I have seen a lot of tutorials and been trying for 2 hours now
I've seen a lot of tutorials and applications that put their jars inside a
I have seen a lot of tutorials and articles showing how to generate barcode
I've seen a lot of helpful tutorials that show one how to: make an

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.