草庐IT

index_length

全部标签

android.database.CursorIndexOutOfBoundsException : Index -1 requested

我正在尝试使用RawContacts.entityIterator读取所有联系人,但我看到了这个错误:android.database.CursorIndexOutOfBoundsException:请求索引-1以下是我的代码:ContentResolvercr=getContentResolver();Cursorcur=cr.query(Contacts.CONTENT_URI,null,null,null,null);Stringid=cur.getString(cur.getColumnIndex(Contacts._ID));if(cur.getCount()>0){whil

android - 无法从 Assets 'index.android.bundle' 加载脚本。确保你的包被正确打包或者你正在运行一个打包服务器

我正在使用版本为0.38.0的ReactNative应用程序,当我尝试将其升级到0.45.1时,它显示以下错误java.lang.RuntimeException:Unabletoloadscriptfromassets'index.android.bundle'.Makesureyourbundleispackagedcorrectlyoryou'rerunningapackagerserver.atcom.facebook.react.cxxbridge.CatalystInstanceImpl.jniLoadScriptFromAssets(NativeMethod)atcom.

android - 无法在 Android Studio 中打开 keystore - "Redundant length bytes found"

我无法在AndroidStudio中打开我现有的keystore文件或从命令行使用jarsigner。在这两种情况下,错误信息都是:java.security.cert.CertificateException:Unabletoinitialize,java.io.IOException:DerInputStream.getLength():Redundantlengthbytesfound见截图:显然这是一个应该用JDK8_131解决的问题但对我不起作用。(我们都在使用OSX)我在travis上也遇到同样的错误。(请参阅下面的“更新”部分。)我发现了另一个SO问题(Signingan

android - 多个R.java中的冗余资源引用导致Dax Index OverflowException

我有多个库项目,它们都依赖于支持库。我的应用程序依赖于这些多个库项目。每个库项目都在其R.java文件中包含支持库资源的引用。由于冗余,这会增加字段ID计数。我的应用获得了DexIndexOverflowException:fieldIDnotin[0,0xffff]:65536因为这个冗余的R.java引用。因此,我的应用程序有47k个方法和65k个字段ID。编辑:我不会使用multi-dex,它不能解决我的问题。我想去除多余的字段ID。问题不在于如何解决该问题,而在于如何摆脱冗余字段ID。使用multi-dex不会删除多余的字段ID。 最佳答案

android - 这个错误java.io.IOException : Content-Length and stream length disagree的原因是什么

我收到这个错误java.io.IOException:Content-Lengthandstreamlengthdisagree在这行代码returnresponse.body().bytes();这是完整的代码编辑:经过一番谷歌后,错误的原因来自okhttplibif(contentLength!=-1L&&contentLength!=bytes.size.toLong()){throwIOException("Content-Length($contentLength)andstreamlength(${bytes.size})disagree")}但是如何解决呢?编辑:这是完整

android - Android 4.0.3 Stock 浏览器 z-index 问题的解决方法/polyfill

我正在为本报告中描述的z-index错误寻找解决方法或polyfill:http://code.google.com/p/android/issues/detail?id=31862我的标记和CSS看起来与错误报告中给出的基本相同。如果有人能给我一个关于如何解决这个问题的正确方向的提示,那就太好了。 最佳答案 我有同样的问题,并通过将以下css添加到我的弹出窗口来修复它:-webkit-transform:translateZ(0); 关于android-Android4.0.3Stoc

Android EditText 长按 : ArrayIndexOutOfBoundsException: length=15; index=491

我有这种我无法解释的奇怪行为。我的布局非常简单:一个EditText:当我尝试长按它(以粘贴一些文本)时,我得到了立即强制关闭和此错误:05-0816:56:16.838:E/AndroidRuntime(12164):FATALEXCEPTION:main05-0816:56:16.838:E/AndroidRuntime(12164):android.view.InflateException:BinaryXMLfileline#17:Errorinflatingclass05-0816:56:16.838:E/AndroidRuntime(12164):atandroid.vie

android - flutter 错误 : RangeError (index): Invalid value: Not in range 0. .2,包括:3

我在Flutter中使用了很长的列表。所有项目都呈现正常,但我也收到以下错误:RangeError(index):Invalidvalue:Notinrange0..2,inclusive:3以下是我的代码:@overrideWidgetbuild(BuildContextcontext){returnContainer(child:getList(),);}以下是我的getList()方法:WidgetgetList(){Listlist=getListItems();ListViewmyList=newListView.builder(itemBuilder:(context,in

android - flutter 错误 : RangeError (index): Invalid value: Not in range 0. .2,包括:3

我在Flutter中使用了很长的列表。所有项目都呈现正常,但我也收到以下错误:RangeError(index):Invalidvalue:Notinrange0..2,inclusive:3以下是我的代码:@overrideWidgetbuild(BuildContextcontext){returnContainer(child:getList(),);}以下是我的getList()方法:WidgetgetList(){Listlist=getListItems();ListViewmyList=newListView.builder(itemBuilder:(context,in

android - WARN in logcat ResourceType : For resource . .., entry index(...) is beyond type entryCount(1)

每次应用程序呈现某些布局时,我都会在logcat上收到这些警告。试图搜索但找不到线索。我认为与资源(可绘制对象、字符串或值)有关,但我不知道是什么原因造成的。这不是错误,但有点烦人。有人有想法吗?04-2215:28:33.20421943-21943/xx.xxx.xxxxxxx.xxxxx.xxxxxW/ResourceType﹕Forresource0x01030128,entryindex(296)isbeyondtypeentryCount(1)04-2215:28:33.20421943-21943/xx.xxx.xxxxxxx.xxxxx.xxxxxW/ResourceT