1

I am able to see facebook groups when I run app for the first time.
But when I close the emulator and run my application again, I am getting the following response.

{Response:  responseCode: unknown, graphObject: null, error: {HttpStatus: -1, errorCode: -1, errorType: null, errorMessage: java.net.UnknownHostException: Unable to resolve host "graph.facebook.com": No address associated with hostname}, isFromCache:false}

I used the following code for fetching Facebook groups:

    Request request = new Request(session, "/me/groups", null, HttpMethod.GET,
            new Request.Callback() {
                @Override
                public void onCompleted(Response response) {
                     //code for displaying groups in list view as response contains groups information

            });
    request.executeAsync();

Am I missing any session handling use cases?

ekad
  • 14,436
  • 26
  • 44
  • 46
chk
  • 51
  • 1
  • 4
  • 1
    Make sure you have always connected to stable internet – Heshan Sandeepa Apr 05 '15 at 12:36
  • @DavidJhons Thanks for the response. I am connected to stable internet. When i run again after "rebuild project" I can get groups. I believe this is something to do session handling. – chk Apr 05 '15 at 13:04
  • Please explain how you can be running an android app after you closed the emulator. – derabbink Apr 08 '15 at 13:07

0 Answers0