Android Studio不是';他没有为我做准备

Android Studio不是';他没有为我做准备,android,android-studio,Android,Android Studio,我刚刚第一次安装了Android Studio,在那些YouTube教程视频中,该应用程序运行良好。但是,由于某些原因,在我的Android Studio中,预览不会加载,它会显示以下消息 “项目同步成功后才能预览。” 我尝试过禁用脱机模式、从父目录中删除gradle文件夹、禁用防火墙、设置代理(它显示连接成功,我使用了代理以太网)和论坛上的所有其他解决方案,甚至重新安装了Studio,但没有一个对我有效。 我不能再使用录音室了。我在Windows10上使用Android Studio 3.5

我刚刚第一次安装了Android Studio,在那些YouTube教程视频中,该应用程序运行良好。但是,由于某些原因,在我的Android Studio中,预览不会加载,它会显示以下消息
“项目同步成功后才能预览。”

我尝试过禁用脱机模式、从父目录中删除gradle文件夹、禁用防火墙、设置代理(它显示
连接成功
,我使用了代理以太网)和论坛上的所有其他解决方案,甚至重新安装了Studio,但没有一个对我有效。
我不能再使用录音室了。我在Windows10上使用Android Studio 3.5

在content_main.xml中输入的代码如下

 <?xml version="1.0" encoding="utf-8"?>
 <androidx.constraintlayout.widget.ConstraintLayout 
 xmlns:android="http://schemas.android.com/apk/res/android"
 xmlns:app="http://schemas.android.com/apk/res-auto"
 xmlns:tools="http://schemas.android.com/tools"
 android:layout_width="match_parent"
 android:layout_height="match_parent"
 app:layout_behavior="@string/appbar_scrolling_view_behavior"
 tools:context=".MainActivity"
 tools:showIn="@layout/activity_main">

 <TextView
     android:layout_width="wrap_content"
     android:layout_height="wrap_content"
     android:text="Hello World!"
     app:layout_constraintBottom_toBottomOf="parent"
     app:layout_constraintLeft_toLeftOf="parent"
     app:layout_constraintRight_toRightOf="parent"
     app:layout_constraintTop_toTopOf="parent" />

 </androidx.constraintlayout.widget.ConstraintLayout>
当我单击给定的链接时,会下载一个.pom文件。 当我单击
启用渐变“脱机模式”并同步项目时
出现以下错误

ERROR: No cached version of com.android.tools.build:gradle:3.5.0 available for offline mode.
Disable Gradle 'offline mode' and sync project
总而言之,这就是问题所在。

构建梯度(应用程序)如下所示

// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        google()
        jcenter()

    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.5.0'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        google()
        jcenter()

    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

你能粘贴包含所有导入的
gradle
文件吗?我该怎么做?只需搜索
build.gradle(app)
并粘贴即可here@Skizo-奥兹ᴉ好了。你能粘贴包含所有导入内容的
gradle
文件吗?我该怎么做?只需搜索
build.gradle(app)
并粘贴即可here@Skizo-奥兹ᴉ你去吧。
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        google()
        jcenter()

    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.5.0'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        google()
        jcenter()

    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}