我在iReport中使用 Excel 文件制作报告。在 Excel 文件中,我使用这些时间类型:
h:mm
yyyy.mm.dd h:mm
当我开始新报告时,我收到以下消息:
Error filling print... Cannot get a text value from a numeric cell
java.lang.IllegalStateException: Cannot get a text value from a numeric cell
我怎么解决这个问题?
<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="report" language="groovy" pageWidth="842" pageHeight="595" orientation="Landscape" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="0d91d166-e8ce-41e5-84a3-281818349b26">
<field name="Related To" class="java.lang.String"/>
<field name="TC Total Time" class="java.lang.String"/>
<field name="TC Start" class="java.lang.String"/>
<field name="TC End" class="java.lang.String"/>
<field name="Assigned To" class="java.lang.String"/>
<field name="TC Name" class="java.lang.String"/>
<field name="TC Description" class="java.lang.String"/>
<field name="Support? " class="java.lang.String"/>
<field name="Support Time" class="java.lang.String"/>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="79" splitType="Stretch"/>
</title>
<pageHeader>
<band height="35" splitType="Stretch"/>
</pageHeader>
<columnHeader>
<band height="61" splitType="Stretch"/>
</columnHeader> <detail>
<band height="125" splitType="Stretch"/>
</detail>
<columnFooter>
<band height="45" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="54" splitType="Stretch"/>
</pageFooter>
<summary>
<band height="42" splitType="Stretch"/>
</summary>
</jasperReport>