I've been researching this error and I found the answer after searching a little bit and found the answer.
I find the answer in the website: www.experts-exchange.com/...
This problem occurs because of memory reserved for the IDE it is too low. so what we need to do is override them.
Proceed like this...
With Android IDE open, just only add this line of code in gradle.properties
and now u click in Try Again...
Your file will look like this:
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
I hope it helped you.