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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T10:07:47+00:00 2026-05-23T10:07:47+00:00

I am new to Android. I am using fbrocket example for status post for

  • 0

I am new to Android. I am using fbrocket example for status post for my application, but I cannot log out from my application. Status message will be posted successfully from this application, but When I close my application, I want to also log out from Facebook.

How can i do this?

Please help me.

My code is here:

package com.drc.Incognito;

import net.xeomax.FBRocket.FBRocket;
import net.xeomax.FBRocket.LoginListener;
import net.xeomax.FBRocket.ServerErrorException;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;

public class Facebook extends Activity implements LoginListener {
    private FBRocket fbRocket;

    Bundle bundle;
    int i;
    String rname,rshopno,raddress,rcity,rphone,remail,rpostcode;

    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        Bundle bundle = getIntent().getExtras();
        rname=bundle.getString("keyshop_name");
        rshopno=bundle.getString("keyshop_no");
        raddress=bundle.getString("keystreet");
        rpostcode=bundle.getString("keypostcode");
        rcity=bundle.getString("keycity");
        rphone=bundle.getString("keyphone");
        remail=bundle.getString("keyemail");
        shareFacebook();

    }
    public void shareFacebook() {
        fbRocket = new FBRocket(this, "PitchFork TRY",
                "c3968bbdd9dc7f44a8e05b7346f46673");

        if (fbRocket.existsSavedFacebook()) {
            fbRocket.loadFacebook();
        } else {
            fbRocket.login(R.layout.main);
        }


    }
    @Override
    public void onLoginFail() {
        fbRocket.displayToast("Login failed!");
        fbRocket.login(R.layout.main);
    }
    @Override
    public void onLoginSuccess(net.xeomax.FBRocket.Facebook facebook) {
        // TODO Auto-generated method stub

        try {
            System.out.println("Incognito Shop:  " +"\n" +rname +"\n" +raddress+ "  " + rshopno +"\n" +rpostcode + " " +rcity + "\n" +rphone +"\n" + remail);
            fbRocket.displayToast("Login success!");
            facebook.setStatus("Incognito Shop:  " +"\n" +rname +"\n" +raddress+ "  " + rshopno +"\n" +rpostcode + " " +rcity + "\n" +rphone +"\n" + remail);

            fbRocket.displayDialog("Status Posted Successfully!! ");
        //  Intent in = new Intent(this,ShopDetail.class);
        //  startActivity(in);  
            facebook.logout();
            finish();

        } catch (ServerErrorException e) {
            if (e.notLoggedIn()) {
                fbRocket.login(R.layout.main);
            } else {
                System.out.println(e);
            }
        }

    }
}

Can you tell me how can I log out from my application when I close my application?

  • 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-23T10:07:48+00:00Added an answer on May 23, 2026 at 10:07 am

    Actually these applications are one-click go applications, so they require username and password only once. Then these application stores them in their private files, so whenever next time the application launches, the user is logged in automatically. This facility is given since the device on which they are using are personal, so no need to logout. But if you want to log out the application, the only way is Clear the data.. Go to Settings -> Applications -> Manage Application -> Select Application -> Clear Data.

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

Sidebar

Related Questions

I imported ApiDemos from android-sdk folder using File/New/Project/Android Project/Create Project Existing Samples. When I
I am new in developing android applications. I want to create an android application(using
I'm using Android 2.3, so according to this post: Streaming Audio from A URL
I'm pretty new to Android dev and still working out a lot of things.
I am using the Android code below to connect to Facebook but getting the
Using my new Android phone established a small problem: I'm living in country A
I am new to Android and am using the Ical4j library for parsing ICS
Calling a .net SOAP1.1 web service from android using ksoap2 lib I met a
I just created a new project in android using eclipse. Just a plain and
I'm quite new to Android programming but familiar with C/C++ and Linux enough to

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.