로그인 후 주문 애플리케이션은 스캐너, 목록 및 주문으로 이동합니다. 주문을 카탈로그로 이동하면 eclipse 가상 장치에서 실행할 수 있지만 모바일에서는 작동하지 않습니다. (30,213 45.174 E/SpannableStringBuilder : 다른 페이지는 이것이 CatalogActivity.javaEclipse에서 실행할 수는 있지만 강제 닫기 모바일
package com.example.barcode;
import java.util.List;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.Button;
import android.widget.ListView;
public class CatalogActivity extends Activity {
private List<Product> mProductList;
Button button;
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.catalog);
// Obtain a reference to the product catalog
mProductList = ShoppingCartHelper.getCatalog(getResources());
// Create the list
ListView listViewCatalog = (ListView) findViewById(R.id.ListViewCatalog);
listViewCatalog.setAdapter(new ProductAdapter(mProductList, getLayoutInflater(), false));
listViewCatalog.setOnItemClickListener(new OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> parent, View view, int position,
long id) {
Intent productDetailsIntent = new Intent(getBaseContext(),ProductDetailsActivity.class);
productDetailsIntent.putExtra(ShoppingCartHelper.PRODUCT_INDEX, position);
startActivity(productDetailsIntent);
}
});
Button viewShoppingCart = (Button) findViewById(R.id.ButtonViewCart);
viewShoppingCart.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
Intent viewShoppingCartIntent = new Intent(getBaseContext(), ShoppingCartActivity.class);
startActivity(viewShoppingCartIntent);
}
});
}
}
입니다
확인하고 여기에 전화
1월 4일부터 9일까지에서 catlog입니다 : 45) : SPAN_EXCLUSIVE_EXCLUSIVE 범위의 길이는 0 일 수 없습니다.
04-09 01:45:45.174 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:48.484 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:48.484 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:56.939 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:56.939 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:57.424 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:57.424 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:57.429 E/System (30213): Uncaught exception thrown by finalizer
04-09 01:45:57.429 E/System (30213): java.io.IOException: close failed: EIO (I/O error)
04-09 01:45:57.429 E/System (30213): at libcore.io.IoUtils.close(IoUtils.java:41)
04-09 01:45:57.429 E/System (30213): at java.io.FileOutputStream.close(FileOutputStream.java:139)
04-09 01:45:57.429 E/System (30213): at java.io.FileOutputStream.finalize(FileOutputStream.java:153)
04-09 01:45:57.429 E/System (30213): at java.lang.Daemons$FinalizerDaemon.doFinalize(Daemons.java:186)
04-09 01:45:57.429 E/System (30213): at java.lang.Daemons$FinalizerDaemon.run(Daemons.java:169)
04-09 01:45:57.429 E/System (30213): at java.lang.Thread.run(Thread.java:856)
04-09 01:45:57.429 E/System (30213): Caused by: libcore.io.ErrnoException: close failed: EIO (I/O error)
04-09 01:45:57.429 E/System (30213): at libcore.io.Posix.close(Native Method)
04-09 01:45:57.429 E/System (30213): at libcore.io.BlockGuardOs.close(BlockGuardOs.java:75)
04-09 01:45:57.429 E/System (30213): at libcore.io.IoUtils.close(IoUtils.java:38)
04-09 01:45:57.429 E/System (30213): ... 5 more
04-09 01:45:57.434 E/System (30213): Uncaught exception thrown by finalizer
04-09 01:45:57.434 E/System (30213): java.io.IOException: close failed: EIO (I/O error)
04-09 01:45:57.434 E/System (30213): at libcore.io.IoUtils.close(IoUtils.java:41)
04-09 01:45:57.434 E/System (30213): at java.io.FileInputStream.close(FileInputStream.java:121)
04-09 01:45:57.434 E/System (30213): at java.io.FileInputStream.finalize(FileInputStream.java:142)
04-09 01:45:57.434 E/System (30213): at java.lang.Daemons$FinalizerDaemon.doFinalize(Daemons.java:186)
04-09 01:45:57.434 E/System (30213): at java.lang.Daemons$FinalizerDaemon.run(Daemons.java:169)
04-09 01:45:57.434 E/System (30213): at java.lang.Thread.run(Thread.java:856)
04-09 01:45:57.434 E/System (30213): Caused by: libcore.io.ErrnoException: close failed: EIO (I/O error)
04-09 01:45:57.434 E/System (30213): at libcore.io.Posix.close(Native Method)
04-09 01:45:57.434 E/System (30213): at libcore.io.BlockGuardOs.close(BlockGuardOs.java:75)
04-09 01:45:57.434 E/System (30213): at libcore.io.IoUtils.close(IoUtils.java:38)
04-09 01:45:57.434 E/System (30213): ... 5 more
04-09 01:45:58.214 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:45:58.214 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:46:00.394 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:46:00.394 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:46:30.454 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:46:30.454 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:46:30.879 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:46:30.879 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:01.334 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:01.334 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:02.439 E/Dynamiclayout(30213): java.lang.IndexOutOfBoundsException: charAt: 0 >= length 0
04-09 01:47:02.664 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:02.664 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:22.089 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:22.089 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:23.169 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
04-09 01:47:23.169 E/SpannableStringBuilder(30213): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
코드의 어떤 줄에서 예외가 발생합니까? – FoamyGuy