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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T21:49:49+00:00 2026-05-21T21:49:49+00:00

In my application, i use tabs and it has settings, home etc tabs. In

  • 0

In my application, i use tabs and it has settings, home etc tabs. In settings page there is a textview with some text. In home page there is an async task which runs in background.

Now what i want is, when user is watching settings page, and if the async task from home.java class completes doInBackground method, i want to update the textview in settings page.

How can i get the reference of the textview of settings page in the onPostExecute method of async task in home.class? Please give some clues or ways to implement this..

thank you..

  • 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-21T21:49:50+00:00Added an answer on May 21, 2026 at 9:49 pm

    You shouldn’t try to access the TextView directly from the onPostExecute() method of your AsyncTask. Instead temporally store the value you want to set to the TextView somewhere centrally, and retrieve it from there when the settings page is accessed.

    To store the value you can use different mechanism. If you don’t need to persist it, you can use a singleton class which can be accessed from very where within you application. To persist the value you should use the shared preferences, a file or a database.

    Check this page for more informations.

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

Sidebar

Related Questions

I have an Android application which has four tabs (I use a main TabActivity
I have an application which has 5 tabs on a TabBarController. For simplicity sake
I am using the jQuery Tabs library in a small application. The page has
I'm using Visual Studio to create my installation package. My application use some bitmap
In our Spring application we use clustered Hibernate Search with ActiveMQ which sets up
In a WPF application I use .txt files for holding some information. An application
In my application I use some icons. Where should I store the path of
I would like to use tabs in my Android application and since TabActivity is
Looking for some best practices of UI list on iPhone which has item add/modify/delete
I'm making a custom GUI for my application. Basically my application has multiple 'tabs'.

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.