我怎样才能纠正validation错误,同时在Android中使用jxl.jar从Excel文件中读取内容
我已经开发了应用程序来显示数据库中的细节清单..数据从Excel文件中提取并存储到数据库中。 当从Excel中读取内容时,我收到错误: java.lang.VerifyError:p41.android.consol.products.StartSectionActivity
我的代码在这里:
公共类StartSectionActivity扩展活动{
Context context=this; public void onCreate(Bundle savedInstanceState){ super.onCreate(savedInstanceState); super.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT); requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.product); try { //int resourceId = context.getResources().getIdentifier("p41.android.consol.products:raw/products.xls", null, null); //File f = new File(context.getResources().openRawResource(resourceId)); File excel=new File("p41.android.consol.products:raw/products.xls"); Workbook book=Workbook.getWorkbook(excel); Sheet sheet1=book.getSheet(0); Cell a1=sheet1.getCell(0, 0); Log.d("Cell Value!", a1.getContents()); /*String files[]=getResources().getAssets().list(null); Log.d("files", files[0]);*/ //InputStream stream=getResources().getAssets().open("PRODUCT_MASTER.xls"); } catch (BiffException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } }
}
- 在android项目中写入excel文件与apache poi
- 从数据库表读取数据并在Android Studio中写入Excel
- android exceptionInInitializerError导致无法确定loggingtypes,而新的HSSFWorkbook(inputStream)
- 在Android上使用jxl修改excel电子表格
- 如何导入/导出Androidstring资源到Excel本地化?
- 我无法input存储在android studio资产文件夹中的excel文件中的数据
- 通过API在我的Android应用程序中查看Excel文件
- 如何做一个循环只有行和固定数量的列?
- testing完成后,生成Android JUnittesting用例的结果