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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T19:22:08+00:00 2026-05-31T19:22:08+00:00

Hy! I am using easyfacebookandroidsdk( http://www.easyfacebookandroidsdk.com/guide.asp ) for posting a status in facebook. I

  • 0

Hy!

I am using easyfacebookandroidsdk( http://www.easyfacebookandroidsdk.com/guide.asp) for posting a status in facebook.

I made a FB App and entered my Android Key Hash.

My Code:

public class FBConnect extends GDActivity implements LoginListener{

     private FBLoginManager fbManager;

     //replace it with your own Facebook App ID
     String title = "Herr der Ringe";

     @Override
     public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      //setContentView(R.layout.main);
      setTitle("Facebook");
      //Bundle extras = getIntent().getExtras();
      //title=extras.getString("title");
    shareFacebook();
     }
     public void shareFacebook() {

            //change the permissions according to the function you want to use 
                    String permissions[] = { "read_stream","publish_actions" };

                    //change the parameters with those of your application
                    fbManager = new FBLoginManager(this, R.layout.main,
                                    "xxxxxxxxx", permissions);

                    if (fbManager.existsSavedFacebook()) {
                            fbManager.loadFacebook();
                    } else {

                            fbManager.login();
                    }
            }

            @Override
            protected void onActivityResult(int requestCode, int resultCode, Intent data) {
                    fbManager.loginSuccess(data);
            }

            public void loginFail() {
                    fbManager.displayToast("Login failed!");

            }

            public void logoutSuccess() {
                    fbManager.displayToast("Logout success!");
            }

            public void loginSuccess(Facebook facebook) {

                    //library use example
                    RestApi rest = new RestApi(facebook);
                    try {

                        rest.setStatus("I just watched "+title+"  and marked it in TVBrain for Android");
                        Log.e("XXX FB","OK");
                    } catch (EasyFacebookError e1) {
                        // TODO Auto-generated catch block
                        Log.e("XXX FB","ERROR");
                        e1.printStackTrace();
                    }



            }



}

Error:

03-25 23:36:42.358: W/Bundle(931): Key status expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:42.365: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:42.365: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:42.365: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:42.365: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:157)
03-25 23:36:42.365: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:42.365: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:42.365: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:42.365: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:42.365: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:42.365: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:42.365: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:42.365: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:42.365: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:42.365: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:42.365: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:42.365: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:42.365: W/Bundle(931): Key access_token expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:42.369: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:42.369: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:42.369: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:42.369: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:157)
03-25 23:36:42.369: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:42.369: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:42.369: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:42.369: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:42.369: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:42.369: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:42.369: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:42.369: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:42.369: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:42.369: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:42.369: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:42.369: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:42.369: W/Bundle(931): Key method expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:42.373: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:42.373: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:42.373: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:42.373: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:157)
03-25 23:36:42.373: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:42.373: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:42.373: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:42.373: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:42.373: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:42.373: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:42.373: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:42.373: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:42.373: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:42.373: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:42.373: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:42.373: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:42.377: W/Bundle(931): Key format expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:42.381: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:42.381: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:42.381: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:42.381: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:157)
03-25 23:36:42.381: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:42.381: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:42.381: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:42.381: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:42.381: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:42.381: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:42.381: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:42.381: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:42.381: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:42.381: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:42.381: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:42.381: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:43.740: W/Bundle(931): Key status expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:43.744: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:43.744: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:43.744: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:43.744: W/Bundle(931):  at com.easy.facebook.android.util.Util.encodePostBody(Util.java:65)
03-25 23:36:43.744: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:184)
03-25 23:36:43.744: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:43.744: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:43.744: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:43.744: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:43.744: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:43.744: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:43.744: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:43.744: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:43.744: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:43.744: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:43.744: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:43.744: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:43.744: W/Bundle(931): Key access_token expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:43.748: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:43.748: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:43.748: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:43.748: W/Bundle(931):  at com.easy.facebook.android.util.Util.encodePostBody(Util.java:65)
03-25 23:36:43.748: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:184)
03-25 23:36:43.748: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:43.748: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:43.748: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:43.748: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:43.748: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:43.748: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:43.748: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:43.748: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:43.748: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:43.748: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:43.748: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:43.748: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:43.748: W/Bundle(931): Key method expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:43.752: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:43.752: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:43.752: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:43.752: W/Bundle(931):  at com.easy.facebook.android.util.Util.encodePostBody(Util.java:65)
03-25 23:36:43.752: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:184)
03-25 23:36:43.752: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:43.752: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:43.752: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:43.752: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:43.752: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:43.752: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:43.752: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:43.752: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:43.752: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:43.752: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:43.752: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:43.752: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)
03-25 23:36:43.752: W/Bundle(931): Key format expected byte[] but value was a java.lang.String.  The default value <null> was returned.
03-25 23:36:43.756: W/Bundle(931): Attempt to cast generated internal exception:
03-25 23:36:43.756: W/Bundle(931): java.lang.ClassCastException: java.lang.String cannot be cast to byte[]
03-25 23:36:43.756: W/Bundle(931):  at android.os.Bundle.getByteArray(Bundle.java:1363)
03-25 23:36:43.756: W/Bundle(931):  at com.easy.facebook.android.util.Util.encodePostBody(Util.java:65)
03-25 23:36:43.756: W/Bundle(931):  at com.easy.facebook.android.util.Util.openUrl(Util.java:184)
03-25 23:36:43.756: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatusCall(RestApi.java:119)
03-25 23:36:43.756: W/Bundle(931):  at com.easy.facebook.android.apicall.RestApi.setStatus(RestApi.java:100)
03-25 23:36:43.756: W/Bundle(931):  at com.korn.tvbrain.overview.FBConnect.loginSuccess(FBConnect.java:72)
03-25 23:36:43.756: W/Bundle(931):  at com.easy.facebook.android.facebook.LoggedInThread$1.handleMessage(LoggedInThread.java:33)
03-25 23:36:43.756: W/Bundle(931):  at android.os.Handler.dispatchMessage(Handler.java:99)
03-25 23:36:43.756: W/Bundle(931):  at android.os.Looper.loop(Looper.java:137)
03-25 23:36:43.756: W/Bundle(931):  at android.app.ActivityThread.main(ActivityThread.java:4424)
03-25 23:36:43.756: W/Bundle(931):  at java.lang.reflect.Method.invokeNative(Native Method)
03-25 23:36:43.756: W/Bundle(931):  at java.lang.reflect.Method.invoke(Method.java:511)
03-25 23:36:43.756: W/Bundle(931):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
03-25 23:36:43.756: W/Bundle(931):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
03-25 23:36:43.756: W/Bundle(931):  at dalvik.system.NativeStart.main(Native Method)

No update appears in facebook.
Please help.

  • 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-31T19:22:10+00:00Added an answer on May 31, 2026 at 7:22 pm

    Uh, the stack trace says that you’re trying to cast a String to a byte[], which sounds like it should work but won’t.

    Hard to say where it’s happening, because you’re using a Facebook API that I’m not familiar with.

    Follow the stack trace until you find a call that’s in your code. Then start from there.

    I’d say that it’s at
    Util.openUrl() in the Facebook API. Does this expect a byte[], and you’re passing a String?

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

Sidebar

Related Questions

Using the http://www.ifans.com/forums/showthread.php?t=132024 post from another question i am allowing the user to enter
Using Google Maps InfoBox - http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobox/docs/reference.html Currently the map will scroll - pan control
Using ASP.NET MVC there are situations (such as form submission) that may require a
Using android 2.3.3, I have a background Service which has a socket connection. There's
Using Android TelephonyManager an application can obtain the state of data activity over the
Using MVC2 I have an AJAX form which is posting to a bound model.
Using Xcode4.2.1, with a basic PhoneGap template based app. (I say template, but I
Using Rails 3.2.0.rc2 and ruby 1.9.3p0 In app/views/requests/_form.html.erb I have the following code for
Using restlet, I want to make a post to android's c2dm service. I have
Using the C# Facebook SDK 5.0.3 everything works fine whit the client.Get(/me). But when

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.