使用Apache POI与Android [英] using Apache POI with Android

查看:725
本文介绍了使用Apache POI与Android的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个经得起考验code从Excel文件中获取信息。它的工作原理在java中的奇迹。然而,当我尝试在Android中使用它,我得到这样的:

I have a tried and tested code to get information from an Excel file. It works wonders in java. However, when I try to use it in Android, I get this:

11-30 13:26:24.339: I/dalvikvm(9762): Could not find method org.apache.commons.codec.digest.DigestUtils.md5, referenced from method org.apache.poi.hssf.usermodel.HSSFWorkbook.addPicture

所以,当我尝试读取一行时,它总是返回null。

So, when I try to read a row, it always returns null.

我怎样才能解决这个问题呢?

How can I fix this problem?

推荐答案

推进到一个答案评论...的Apache POI有少量的 的依赖,这是在网站上的组件页面全面上市。您需要包括你使用任何POI模块的依赖关系。在你的情况,你有指定的异常下议院codeC库失踪,并称解决了这个问题。

Promoting a comment to an answer... Apache POI has a small number of dependencies, which are fully listed on the Components page on the website. You need to include the dependencies of whichever POI modules you're using. In your case, the exception you got indicated that the Commons Codec library was missing, adding that solves the issue.

这篇关于使用Apache POI与Android的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆