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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T11:55:56+00:00 2026-06-03T11:55:56+00:00

I have a custom Array Adapter to display a list of items, in this

  • 0

I have a custom Array Adapter to display a list of items, in this case, highscores. The system sort of mimics a folder scheme; one clicks a folder named “Game 1” and it goes to a new list with the top 10 scorers. When you take a test, it changes a sharedpreferences called isPlayed, and if isPlayed is 1, the image for that Game, Game 1, is green, otherwise, if you never play Game 1, isPlayed is never 0, and therefor the image on the highscore list of games is red. But, SharedPreferences seems to be unknown in a class that extends ArrayAdapter. How can I use data from sharedpreferences here? Post a question if you need more info.

  • 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-03T11:56:00+00:00Added an answer on June 3, 2026 at 11:56 am

    You can access SharedPreferences with –

    getContext().getSharedPreferences(String name, int mode)

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

Sidebar

Related Questions

I have a listview connected to a custom array adapter. This list shows information
I have list view with custom array adapter. I want to get items click
I have used a custom array adapter to populate my list view.The problem i
I have list activity with custom array adapter and I can't to get context
I have an array of custom objects. MyCustomArr[]. I want to convert this to
I am using a custom List adapter to display a list of all contacts,
I have a listview with custom array adapter, the view allows the user to
So I have a custom ListView object. The list items have two textviews stacked
I have a listview with a custom array adapter: public class SmsMessageAdapter extends ArrayAdapter<ContactMessage>
I have created a custom ArrayAdapter to display data within ListView items from 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.