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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T22:59:27+00:00 2026-05-25T22:59:27+00:00

Im currently developing an application for android, the first screen of the application is

  • 0

Im currently developing an application for android, the first screen of the application is the LoginActivity, it is authenticating with facebook and a facebook login dialog is shown on users request. The whole login process is working great, when you have logged in user are brought to a new activity. I’ve created a logout function in that activity which logging the user out of facebook in the whole application, but. If you press the “back-button” on an android device when the user is at the activity where you are when you have logged in the loginactivity is shown for the user. I want to make it impossible for the user to show the loginactivity but i don’t know how. When the user successfully logging in from the beggining the following lines are runned:

        Intent intent = new Intent().setClass(LoginActivity.this, LocationActivity.class);
        startActivity(intent);

And when the user successfully logged out from the MainActivity the following lines are runed:

ApplicationController appController = (ApplicationController)getApplicationContext();
            appController.setfullnametoNull();
            appController.setuseridtoNull();
            finish();

Any suggestions on how to make it impossible for the user to get to the loginactivity when the user is currently logged in?

  • 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-25T22:59:27+00:00Added an answer on May 25, 2026 at 10:59 pm

    finish() the activity and if the user navigates to other app without log out then you should check in the login activity when comes back to app and redirect the user to appropriate activity. You need to save the login credentials for this. You can use SharedPreferences for this.

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

Sidebar

Related Questions

I am currently developing my first Android application by reading Dev Documentation at Android
I'm currently developing my first android application. I want the user of my application
I'm currently developing an Android application that fetches images using http requests. It would
I am having trouble with developing my Android application, I am currently using Eclipse
I am currently developing an android application and required to get the browser version.
I am currently developing an android application uses Google map API. I am wondering
I'm currently developing an application to manage my pictures on an Android phone. I
I'm currently developing an application for Android which needs to use a custom made
I am developing my first Android application. I have created a relativelayout with two
I am currently developing an android application and every now and then I am

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.