找不到符号导入com.google.android.gms.R

时间:2018-11-02 15:34:25

标签: android eclipse mobile-application

我在尝试在android studio中执行应用时遇到此错误“找不到符号导入com.google.android.gms.R”, 该应用程序是在Eclipse中开发的,并导入到android studio中。

 Error details:
    symbol:   class R
    location: package com.google.android.gms
 Note: Some input files use or override a deprecated API.
 Note: Recompile with -Xlint:deprecation for details.
 1 error
 :app:compileDebugJavaWithJavac FAILED

 FAILURE: Build failed with an exception.

 * What went wrong:
 Execution failed for task ':app:compileDebugJavaWithJavac'.
 > Compilation failed; see the compiler error output for details.

 * Try:
 Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

1 个答案:

答案 0 :(得分:0)

您是否尝试过Build-> clean项目,然后尝试Build-> Rebuild项目,File-> Invalidate缓存并重新启动。这些可能有效,不确定。我通常会针对此类错误执行这些步骤