简体   繁体   English

Android Studio上的Gradle项目同步失败

[英]Gradle Project Sync Failed on Android Studio

I am new to Android App development.I installed Java Development Kit andAndroid Studio v 3.0.1 . 我是Android App开发的新手,我安装了Java Development Kit和Android Studio v 3.0.1。 There was no problem in downloading and installing Android Studio. 下载和安装Android Studio没问题。 The problem came when the time came to creat a new project. 问题来了,是时候创建一个新项目了。 My instructor on the course told me the new project would take time to set up and configure. 我的课程讲师告诉我,新项目将花费一些时间来设置和配置。 Mine took some 115 minutes. 我花了大约115分钟。 And after it came a Windows Alert Message mentioning that Windows Firewall has blocked some features of JDK library. 随后,出现Windows警告消息,其中提到Windows防火墙阻止了JDK库的某些功能。

This is the screen shot of the Windows Alert Message. 这是Windows警报消息的屏幕截图。

Windows Alert Message Windows警报消息

I just ignored the message, and clicked the Close button. 我只是忽略了该消息,然后单击了“关闭”按钮。 And when I see my newly opened project on Android Studio, I see the message that Gradle Project sync failed.Basic functionlity will not work properly. 当我在Android Studio上看到新打开的项目时,看到了Gradle Project同步失败的消息,基本功能将无法正常运行。

This is the screenshot of Gradle Error. 这是Gradle Error的屏幕截图。 Gradle Project Sync Failed Gradle项目同步失败

I am clueless about what this Gradle is. 我对这个Gradle是什么一无所知。 Does this gradle error have anything to do to do with the Windows Alert Message I ignored? 此gradle错误与我忽略的Windows警报消息有什么关系吗? How can I fix this problem? 我该如何解决这个问题? I want to create apps and just new to Android App development. 我想创建应用程序,并且只是Android应用程序开发的新手。

Windows Firewall automatically blocked Internet access for Android Studio and informed you about that in that dialog. Windows防火墙会自动阻止Android Studio的Internet访问,并在该对话框中通知您。 Most programs, like Android Studio need Internet access, so in the future you want to click "Allow access" button whenever that dialog show up (for trusted software). 大多数程序(例如Android Studio)都需要Internet访问,因此将来您希望在该对话框出现时单击“允许访问”按钮(对于受信任的软件)。

Go to Windows Firewall and in the "Allow a program or feature through Windows Firewall" option look for "OpenJDK Platform binary" and check both checkboxes. 转到Windows防火墙,然后在“允许程序或功能通过Windows防火墙”选项中查找“ OpenJDK Platform二进制文件”,然后选中两个复选框。

Screenshot tutorial , but for Firefox 屏幕截图教程 ,但适用于Firefox

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM