Simple Fellow
Simple Fellow

Reputation: 4622

Need help in "Gradle DSL method not found" in Android Studio

I'm rather new to android development. I have been pulling my hair for days and have not been able to figure out how to get it to compile. I use

Android Studio 3.1.1 Build #AI-173.4697961, built on April 4, 2018 JRE: 1.8.0_152-release-1024-b02 amd64 JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o Windows 10 10.0

Now whenever I try to compile I get this beautiful colorful message that smiles and says: gradle error

corresponding Event log

gradle.build (Module level)

sample app gradle build

How can I get to successful compilation? what am I doing wrong here? I'm a newbie so do not assume things. I really don't know how to fix this. tried a few things that are there on the net but none of them works. besides they all are for android studio 2.x something. so maybe those solutions do not apply

Upvotes: 1

Views: 700

Answers (1)

CommonsWare
CommonsWare

Reputation: 1006724

The second line of your last screenshot is:

ext.kotlin_version = '1.2.30' '1.1.2-5'

That is not valid Groovy syntax, and your error is complaining about a 1.2.30() method invocation, which fits.

Remove one of those two strings. Since 1.2.30 is newer, I suggest trying:

ext.kotlin_version = '1.2.30'

Upvotes: 3

Related Questions