[英]Error:An error occurred configuring project ':app'. > The SDK directory does not exist
i am importing one project. 我正在导入一个项目。 i am running this on linux.
我在linux上运行它。 but when i build my project it gives me this error.
但是当我建立我的项目时,它给了我这个错误。
**Error:A problem occurred configuring project ':app'. **错误:配置项目':app'时发生问题。
The SDK directory '/home/custom/Documents/Zebra_RFID_Mobile-1.0.2.17/C:\\Users\\DHXW76\\AppData\\Local\\Android\\Sdk' does not exist.**
SDK目录'/home/custom/Documents/Zebra_RFID_Mobile-1.0.2.17/C:\\Users\\DHXW76\\AppData\\Local\\Android\\Sdk'不存在。**
Below is my local.properties file以下是我的local.properties文件
## This file is automatically generated by Android Studio.
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
#
# This file must *NOT* be checked into Version Control Systems,
# as it contains information specific to your local configuration.
#
# Location of the SDK. This is only used by Gradle.
# For customization when using a Version Control System, please read the
# header note.
#Mon Sep 11 14:54:05 IST 2017
ndk.dir=/home/custom/Android/Sdk/ndk-bundle
sdk.dir=/home/custom/Android/Sdk
I am wondering that how is this error showing c:\\users.... path, although i am trying it to run this on linux. 我想知道这个错误如何显示c:\\ users ....路径,尽管我正在尝试在Linux上运行它。 I have also checked my sdk location, it is perfect.
我还检查了我的SDK位置,这是完美的。 can anybody help me solve this issue?
有人可以帮我解决这个问题吗?
I had this problem. 我有这个问题。 I'm using Linux.
我正在使用Linux。 Project stucture windows
项目结构窗口
How I corrected the error: 我如何纠正错误:
2.Checking Gradle. 2.检查Gradle。 Gradle Folder Gradle The version number in the Project Structure /project and in the
/opt/android-studio/gradle/gradle-4.6/
folder should be the same. Gradle文件夹 Gradle项目结构/ project和
/opt/android-studio/gradle/gradle-4.6/
文件夹中的版本号应该相同。 If the problem persists, update the Gradle. 如果问题仍然存在,请更新Gradle。
2.1 We go to the site: https://gradle.org/install/#with-a-package-manager and download the binary version. 2.1我们转到以下站点: https : //gradle.org/install/#with-a-package-manager并下载二进制版本。 Download the archive we throw in the folder
/opt/android-studio/gradle/gradle-4.6/
and write down its version number in Project Structure /project. 下载我们放入
/opt/android-studio/gradle/gradle-4.6/
文件夹中的/opt/android-studio/gradle/gradle-4.6/
并在Project Structure / project中写下其版本号。
3.Restart the studio. 3.重新启动工作室。
If the program code shows an incorrect version of Gradle, then an error will appear that is difficult to fix. 如果程序代码显示了不正确的Gradle版本,则将出现难以修复的错误。 Try to check all the code or create a new project.
尝试检查所有代码或创建一个新项目。
Check Gradle easily by creating a new project. 通过创建新项目轻松检查Gradle。 I like this method.
我喜欢这种方法。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.