Java 在eclipse中添加编辑文本时出错
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/24592647/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Error in adding an edit text in eclipse
提问by Mash
I'm building an Android app for a tablet. I'm trying to add an EditText
in my graphical view in Eclipse but whenever I choose EditText
from the widget and drop to the graphical view, the screen turn gray and i get this error
我正在为平板电脑构建一个 Android 应用程序。我想补充一个EditText
我在Eclipse图形视图,但每当我选择EditText
从窗口小部件并拖放到图形视图,屏幕变成灰色,我得到这个错误
" Exception raised during rendering: java.lang.System.arraycopy([CI[CII)V
Exception details are logged in Window > Show View > Error Log"
How to fix this problem?
如何解决这个问题?
采纳答案by Rafael
In the new update come the 4.4W (Android Wear) and he doesnt support EditText
, so the best and simple way to solve is deleting 4.4W.
新的更新来了4.4W(Android Wear),他不支持EditText
,所以最好最简单的解决方法就是删除4.4W。
Go to
去
Window > Android SDK Manager > check Android 4.4W(API 20) > Delete package
窗口 > Android SDK 管理器 > 检查 Android 4.4W(API 20) > 删除包
Maybe then you can't create a new project, so you back to SDK manager and download another version like 4.4.2(API 19).
也许那时您无法创建新项目,因此您返回 SDK 管理器并下载另一个版本,例如 4.4.2(API 19)。
It works for me, hope for you too.
它对我有用,希望对你也有用。
回答by Rolf Beh
Android W(atch) doesn't support Text Fields.
Android W(atch) 不支持文本字段。
Lower the API level to <=19 and it should work.
将 API 级别降低到 <=19,它应该可以工作。
This was mentioned in https://stackoverflow.com/a/24473444/666208
回答by androidExplorer
No need to delete the API 20 package.
无需删除 API 20 包。
this problem happened on API 20 ( Android 4.4 W ) I recently have a problem with that but Problem will be solved by changing Android version to use for rendering level form API 20 ( Android 4.4 W ) to API 19 (Android 4.4.2) ( android icon in top right corner of graphical layout ) or update your SDK to Android L ( API 20 L preview )
这个问题发生在 API 20 ( Android 4.4 W ) 我最近有一个问题,但问题将通过将 Android 版本更改为用于渲染级别表单 API 20 ( Android 4.4 W ) 到 API 19 (Android 4.4.2) (图形布局右上角的 android 图标)或将您的 SDK 更新为 Android L(API 20 L 预览版)
Reference: Exception raised during rendering: java.lang.System.arraycopy