Error:Error converting bytecode to dex: Cause: Dex cannot parse version 52 byte code. This is caused by library dependencies that have been compiled using Java 8 or above. If you are using the 'java' gradle plugin in a library submodule add targetCompatibility = '1.7' sourceCompatibility = '1.7' to that submodule's build.gradle file.
Judging by the error you need to add targetCompatibility and sourceCompatibility in the gradle. How can this be done? If you can give an example, please.
Gradle file
configurations.maybeCreate("default") artifacts.add("default", file('sqljdbc42.jar')) android { compileOptions { targetCompatibility JavaVersion.VERSION_1_7 sourceCompatibility JavaVersion.VERSION_1_7 } }