在Android项目中创建一个包含main()方法的类,直接右键运行该类时会报如下错误:

#
# An unexpected error has been detected by Java Runtime Environment:
#
# Internal Error (classFileParser.cpp:2923), pid=7780, tid=7832
# Error: ShouldNotReachHere()
#
# Java VM: Java HotSpot(TM) Client VM (11.0-b15 mixed mode windows-x86)
# An error report file with more information is saved as:
# D:\编程代码集\Android\HelloAndroid\hs_err_pid7780.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#



http://stackoverflow.com/questions/2543106/fatal-error-by-java-runtime-environment链接中找到了解决方法:

具体解决方法如下:
1.选中项目,右键 -> Run As -> Run Configurations...

2.在Java Aplication(或你对应的分类)中找到你刚运行的项目
3.切换到Classpath选项栏,点击Bootstrap Entries里面的Android Library,然后点击右侧的Advanced.. -> Add Library -> JRE System Library,一路next即可。



                            ====================================================================================

  作者:欧阳鹏  欢迎转载,与人分享是进步的源泉!

  转载请保留原文地址:http://blog.csdn.net/ouyang_peng

====================================================================================

 

我的Android进阶之旅------>解决 Error: ShouldNotReachHere() 问题的更多相关文章

  1. 我的Android进阶之旅------>解决Error: specified for property 'mergedManifest' does not exist.

    错误描述 刚运行从Github上面下载而来的代码时,爆了如下所示的bug,错误描述如下所示: Error:A problem was found with the configuration of t ...

  2. 我的Android进阶之旅------>解决Error:Unable to find method 'org.gradle.api.internal.project.ProjectInternal.g

    错误描述 今天在Github上面下载了一份代码,然后导入到Android Studio中直接报了如下图所示的错误: 错误描述如下: Error: Unable to find method 'org. ...

  3. 我的Android进阶之旅------>解决Error:Could not find property 'compile' on org.gradle.api.internal.artifacts.

    1错误描述 解决方法 1错误原因 2解决方法 1.错误描述 刚刚,Android Studio突然编译不了了,报了如下错误: Error:Could not find property 'compil ...

  4. 我的Android进阶之旅------>解决Jackson等第三方转换Json的开发包在开启混淆后转换的实体类数据都是null的bug

    1.错误描述 今天测试人员提了一个bug,说使用我们的app出现了闪退的bug,后来通过debug断点调试,发现我们的app转换服务器发送过来的json数据后,都是为null.而之前已经提测快一个月的 ...

  5. 我的Android进阶之旅------>解决Your project contains error(s),please fix them

    在使用eclipse写好Android的代码,代码没有报错.然后想在AVD中运行测试时,弹出错误框,提示信息为:  "Your project contains error(s),pleas ...

  6. 我的Android进阶之旅------>报 error: Apostrophe not preceded by \ 的错误解决办法

    今天对项目进行国际化翻译的时候控制台出现了以下的错误: res/values/strings.xml:100: error: Apostrophe not preceded by \ (in Sorr ...

  7. 我的Android进阶之旅------>解决Android Studio报错:DefaultAndroidProject : Unsupported major.minor version 52.0

    问题描述 今天使用Android Studio 2.0打开我之前的项目时,编译报了如下错误: Error:Cause: com/android/build/gradle/internal/model/ ...

  8. 我的Android进阶之旅------>解决Android Studio编译后安装apk报错:The APK file does not exist on disk

    1.错误描述 今天用Android Studio编译应用后安装APK的时候,报错了,错误如下所示: The APK file build\outputs\apk\OYP_2.3.4_I2Base_64 ...

  9. 我的Android进阶之旅------>解决:debug-stripped.ap_' specified for property 'resourceFile' does not exist.

    1.错误描述 更新Android Studio到2.0版本后,出现了编译失败的问题,我clean project然后重新编译还是出现抑郁的问题,问题具体描述如下所示: Error:A problem ...

随机推荐

  1. LeetCode 14: Longest Common Prefix

    Longest Common Prefix Write a function to find the longest common prefix string amongst an array of ...

  2. 使用Java取得本机IP和机器名

    try { InetAddress addr = InetAddress.getLocalHost(); String ip=addr.getHostAddress().toString();//获得 ...

  3. 不依赖Excel是否安装的Excel导入导出类

    本文利用第三方开源库NPOI实现Excel97-2003,Excel2007+的数据导入导出操作. 不依赖Office是否安装.NPOI开源项目地址:http://npoi.codeplex.com/ ...

  4. Android JNI/NDK开发教程

    JNI/NDK开发指南:http://blog.csdn.net/xyang81/article/details/41759643

  5. scrapy 安装详解

    一. Scrapy简介 Scrapy is a fast high-level screen scraping and web crawling framework, used to crawl we ...

  6. Oracle ODBC无Oracle连接驱动

    .下载odbc驱动 需要下载两个东西 instantclient.zip instantclient.zip 下载地址:http:.html 解压放到同一个目录(无冲突) .将oracle数据库所在电 ...

  7. jquery插件:aotocomplete

    aotocomplete.js http://blog.csdn.net/smeyou/article/details/7980273?_t_t_t=0.3565731019350138 $(func ...

  8. 解决H5在微信浏览器或QQ浏览器修改title的问题

    传送门:http://blog.csdn.net/code_for_free/article/details/51195468 如果是Android,使用 document.title = ‘1231 ...

  9. ACM算法整理(不断补充ing)

    动态规划 1.背包问题 (1)01背包 ,n) DFR(v,V,C[i]) F[v]=max(F[v],F[v-C[i]]+W[i]); } //初始化时 //若背包不一定装满F全初始化为0 //若装 ...

  10. Sphinx之配置文件

    # # Sphinx configuration file sample # # WARNING! While this sample file mentions all available opti ...