4

I have follow Scott Barta solution to import Facebook SDK on the new version of Android Studio (here) but now i'm having trouble using this sdk.

When I import import com.facebook.android.Facebook;I can't run my apps, it keeps reporting error: package com.facebook.android does not exist and all my methods that refer to facebook are "deprecated".

Does anyone know where this could come?

Community
  • 1
  • 1
  • This could be a lot of things. First you need to check if the Facebook library is imported, if the library is imported then you need to check if your resource file (R.java) is being generated, sometime another error prevent the resource file to be generated and this can brake all your app. Sorry if this isn't so helpful but I never imported a library fallowing the steps in your link. – GhostDerfel Mar 20 '14 at 19:43

1 Answers1

0

I have been facing similar issues with the latest Facebook SDK update, if you're using Gradle, I'll strongly recommend you, to first try to do a Gradle Sync as you can see here:

https://stackoverflow.com/a/19932896/799162

If that doesn't work ( as my case) you can force gradle to download your dependencies as shown here:

https://stackoverflow.com/a/13567793/799162

as an extra thing to do, try to do a clean on your build.

Community
  • 1
  • 1
moxi
  • 1,390
  • 20
  • 21