Error:Could not run build action using Gradle inst

2019-01-17 03:56发布

Ive just installed android studio 1.0 RC2 in a windows 8.1 64bits, but when i try to create a new project it says Error:Could not run build action using Gradle installation 'C:\Program Files\Android\Android Studio1\gradle\gradle-2.2.1'., please help me solve this proplem, im really stuck in this

2条回答
男人必须洒脱
2楼-- · 2019-01-17 04:00

Try this:

1) File -> Invalidate caches / Restart

2) Shutdown Android Studio

3) Remove .gradle folder in the user home directory

4) Restart Android Studio let it download all the Gradle stuff it needs

5) Gradle build success !

6) Rebuild project.... success !

查看更多
爷、活的狠高调
3楼-- · 2019-01-17 04:20

We have two famous way for this problem:

1- update the gradle:

step 1:

Get latest version supported by Android Studio from:

https://services.gradle.org/distributions

step 2:

Extract the gradle file and install to dists folder(gradle folder): default location is: C:\Users[username]\gradle\wrapper\dists

step 3:

Open Android Studio: File/Settings/Gradle/Service directory path: (Change to folder you set above) and Click ok.

Status on bottom should indicate it's busy & error should be fixed.

step 4:

restart Android Studio

2- Delete the .gradle folder:

default location is:

C:\Users[username]\gradle\wrapper\dists

after that open Android Studio and make a new project (might need to reastart).

查看更多
登录 后发表回答