首页 文章

错误:错误:无法创建Java虚拟机

提问于
浏览
0

Hello Guys我在生成sign apk时发现了这个错误 .

Error:Error: Could not create the Java Virtual Machine.
Error:Error: A fatal exception has occurred. Program will exit.
Error:Invalid maximum heap size: -Xmx4g
Error:The specified size exceeds the maximum representable size.

我的配置 - Android Studio 3.0.1 Build#AI-171.4443003,建于2017年11月9日JRE:1.8.0_152-release-915-b01 amd64 JVM:OpenJDK 64位服务器VM by JetBrains s.r.o Windows 10 10.0

2 回答

  • 0

    检查项目使用的java版本 . 它可以与Studio使用的不同 .

    例如 :

    enter image description here

  • 0

    很棒的工作!!!谢谢@olikaf和@ChrisStillwell

相关问题