Could not find provider information for com.facebook.katana.provider.platformprovider and com.facebook.wakizashi.provider.platformprovider

In my android app I am using FacebookDialog.

I am writing the following code.

On the Galaxy Note3 (Android4.4.2), everything is going well.

However, in Experia SOL21 (Android4.1.2) this is not the case. Below is the error code.

[My code] in Activity.java

 private UiLifecycleHelper uiHelper;

 private void FbShare(String shareTitle, String shareUrl,String shareImageUrl) {
    if (FacebookDialog.canPresentShareDialog(getApplicationContext(),
            FacebookDialog.ShareDialogFeature.SHARE_DIALOG)) {
        try {
            FacebookDialog shareDialog = new FacebookDialog.ShareDialogBuilder(
                    this).setDescription(shareTitle).setName(shareTitle)
                    .setLink(shareUrl).setPicture(shareImageUrl)
                    .setApplicationName("myapp").build();
            uiHelper.trackPendingDialogCall(shareDialog.present());
        } catch (FacebookException e) {
            Toast.makeText(this, "Facebook Error1",Toast.LENGTH_SHORT).show();
        }
    }
    else Toast.makeText(this, "Facebook Error2",Toast.LENGTH_SHORT).show();
}

      

[Error log]

Failed to find provider info for com.facebook.katana.provider.platformprovider
Failed to find provider info for com.facebook.wakizashi.provider.platformprovider

      

Plus, Toast in Activity.java says "Facebook2 error".

I have correctly added the permission to access the metadata of the manifest and facebookSDK as shown below.

<uses-permission android:name="android.permission.INTERNET" />

<meta-data
   android:name="com.facebook.sdk.ApplicationId"
   android:value="@string/app_id" />

      

Could you please tell me how to solve this problem?

+3


source to share





All Articles