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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T15:01:38+00:00 2026-05-19T15:01:38+00:00

I have 3 webviews in my search engine app.When the user enters his query,

  • 0

I have 3 webviews in my search engine app.When the user enters his query, by default he gets Google results, followed by yahoo and Ask buttons at the bottom, on clicking either of them, he gets results for that query from those sites. Now I want to give the user the privilege to change the default result site. I have created 3 radiobuttons. Upon confirmation, say he chooses Yahoo, how can i set it as Yahoo till the next time he changes it to some other site,

  • 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-19T15:01:39+00:00Added an answer on May 19, 2026 at 3:01 pm

    Accessing data from SharedPreferences:

    SharedPreferences sharedPref = getSharedPreferences("FileName",MODE_PRIVATE);
    String webViewChoice = sharedPref.getString("userChoice","null");
    

    if no choice was saved (in the case when the application is running for the first time), you’ll get “null” in webViewChoice.
    use this condition as you wish

    Saving data in SharedPreferences:

    SharedPreferences sharedPref = getSharedPreferences("FileName",MODE_PRIVATE);
    SharedPreferences.Editor prefEditor = sharedPref.edit();
    prefEditor.putString("userChoice",usersChoice);
    prefEditor.commit();
    

    I hope it helps.

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

Sidebar

Related Questions

I want the user to input their search query into a search widget and
Hello i have app with webviews and i embed youtube video. Now i have
I have a view controlled app. On my xib I have no webviews but
What I need: I need to have different WebViews inside a ViewFlipper and then
I have an application that uses multiple WebViews. Nowhere do I set the priority
I have an application with tabs that are all webviews. I'm using UIWebViewDelegate so
In an application that has multiple webviews, is there any way to have the
So I have made a text field, where I can search a web or
I am making an android app in which i have to show Hash Tag
I have a webview that performs a search, this code works great for below

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.